mhelmer / dockerize-uwsgi-nginx-webpack

Dockerized Django REST Framework + UWSGI, Nginx, Webpack + React + Redux
14 stars 7 forks source link

Nginx deployment configuration issue #6

Closed oscanog closed 8 years ago

oscanog commented 8 years ago

issue

mhelmer commented 8 years ago

Hi,

First thing, I noticed I forgot to map port 80 from the nginx container. So, I guess what you're seing is served by your host system.

Secondly I have not added a production config for webpack (minified, without source maps, production node env etc).

These settings never found it back here because I'll usually do production setup way later than dev. Anyway, I will fix those problems within a few days. Just beware the it is not secure to run it in production as it is, since it should run in HTTPS only.

mhelmer commented 8 years ago

I suppose you did the following?

docker-compose -f docker-compose.yml -f docker-compose.prod.yml build
docker-compose -f docker-compose.yml -f docker-compose.prod.yml up
oscanog commented 8 years ago

yep, I did.

mhelmer commented 8 years ago

This should be fixed now. Just make sure to add your ssl certs or set up letsencrypt by following the links in README.md. Also configure the django production settings with ALLOWED_HOSTS etc..