Article 6J6RB Which folders are suitable for storing / serving production frontend and backend code?

Which folders are suitable for storing / serving production frontend and backend code?

by
charliegreen
from LinuxQuestions.org on (#6J6RB)
I have an Amazon Linux (EC2) instance that I'm using to host a web application that consists of React front end and a python Flask api backend. I'm using Nginx to serve the application. So far I have placed everything as follows during development,

- python virtual env is stored in /home/ec2-user/pyenv/ folder

- frontend is located in nginx folder /usr/share/nginx/react-frontend

- backend is located under same nginx folder /usr/share/nginx/flaskapi

- my sqlite db, log file, and temp working directory are in same location as backend code /usr/share/nginx/flaskapi/log.db, /usr/share/nginx/flaskapi/log.txt, /usr/share/nginx/flaskapi/tmp/

I need to create a new user to run everything with permission only to the files/folders needed, so I wanted to know is it ok to leave everything where it is on the server or should I relocate somewhere more appropriate?
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments