Skip to content
Snippets Groups Projects
Commit e27e6015 authored by Tim G's avatar Tim G
Browse files

Adjusted Docker files for production setup

parent d9ba01a2
No related branches found
Tags 0.4.0
No related merge requests found
......@@ -7,6 +7,7 @@ services:
restart: always
volumes:
- ./initdb:/docker-entrypoint-initdb.d
- ./persistent_db:/var/lib/postgresql
networks:
- default
environment:
......@@ -15,6 +16,7 @@ services:
POSTGRES_PASSWORD: password
http:
container_name: ap_http
restart: always
image: nginx
volumes:
- ./docker/nginx.conf:/etc/nginx/conf.d/default.conf
......@@ -23,13 +25,16 @@ services:
- traefik
labels:
- 'traefik.enable=true'
- 'traefik.backend=web'
- 'traefik.port=8000'
- 'traefik.backend=ap_http'
- 'traefik.port=80'
- 'traefik.docker.network=traefik_net'
- 'traefik.frontend.rule=Host:antholont.ecrituresnumeriques.ca'
- 'traefik.frontend.rule=Host:prod-ap.ecrituresnumeriques.ca'
app:
container_name: ap_python
image: timoguic/antholont
restart: always
image: timoguic/antholont:stable
environment:
- DJANGO_SETTINGS_MODULE=anthology.settings.prod
depends_on:
- db
networks:
......
#!/bin/bash
cd /code || exit
set -ex
cd /code
python manage.py migrate
python manage.py compilemessages
python -m gunicorn -b 0.0.0.0:8000 anthology.wsgi
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment