I have a Django project that serves an API with django-rest to an Angular SPA. Currently the Angular is served by Django (it's in the static folder). This is really convenient because it makes working on it very easily locally with just one manage.py run server
.
On AWS, Django is on an nginx EC2 web server. And all the static files, including angular are on the S3. This works fine for the moment. But I'm sensing that it will soon lead to some difficulties and I would like to separate completely the angular project from the django one (even different github repos).
Therefore my infrastructure would look like that :
- S3 :
- Angular App
- Django static and media files
- EC2 :
- Django app
As opposed to current :
- S3 :
- Django static files (including Angular App) and media files
- EC2 :
- Django app
How can I achieve that ? And how this will change the way I launch my server locally ?