2

Note: I have already gone through following answers Serving static files with Nginx + Gunicorn + Django & How exactly do I server static files with nginx and gunicorn for a Django app?

I am using Django along with AngularJS & have deployed the application on Nginx & Gunicorn on AWS. Currently, I have deployed Nginx & Gunicorn on two different EC2 instances. Is it the ideal way to deploy the above configuration?

How to serve the static content? Is it advisable to deploy AngularJS templates from S3 along with CSS, JS & images?

I think there is a better way to handle this. It will be really helpful if someone can guide me to better understand the deployment details for this configuration.

Thanks!

Community
  • 1
  • 1
krishnaxv
  • 956
  • 2
  • 6
  • 18

1 Answers1

0

You can do using apache. Just configure the path of the index file in apache configuration.

(or)

the simplest approach is to go to /var/www/html and place the index file in here. It will be automatically served, and place the static files(images) in S3.

Please dont put the angular files in S3. Arrange and place all css & js files with the index.html. Hope this is helpful.

SuperNova
  • 25,512
  • 7
  • 93
  • 64