2017-10-08 20:24:18 +00:00
|
|
|
version: "3.3"
|
2017-05-20 23:52:01 +00:00
|
|
|
services:
|
|
|
|
map:
|
2017-10-08 20:24:18 +00:00
|
|
|
restart: always
|
2017-05-20 23:52:01 +00:00
|
|
|
build: .
|
|
|
|
links:
|
|
|
|
- db:db
|
|
|
|
- cache:cache
|
2017-10-08 20:24:18 +00:00
|
|
|
networks:
|
|
|
|
- web
|
|
|
|
labels:
|
|
|
|
- "traefik.backend=app"
|
|
|
|
- "traefik.frontend.rule=Host:map.ojuso.org"
|
|
|
|
- "traefik.frontend.priority=5"
|
|
|
|
- "traefik.frontend.passHostHeader=true"
|
2017-05-20 23:52:01 +00:00
|
|
|
volumes:
|
2017-10-08 20:21:51 +00:00
|
|
|
- ./apps:/app/apps
|
|
|
|
- ./ojusomap:/app/ojusomap
|
2017-10-31 14:57:26 +00:00
|
|
|
- ./support:/app/support
|
2017-05-20 23:52:01 +00:00
|
|
|
- /containers/map/static:/app/static
|
|
|
|
- /containers/map/gunicorn.sock:/app/gunicorn.sock
|
|
|
|
env_file:
|
2017-10-31 15:00:44 +00:00
|
|
|
- ./environment
|
|
|
|
command: /bin/sh -c "DEBUG=1 python3 manage.py collectstatic --noinput && python3 manage.py compilemessages && python3 manage.py migrate && gunicorn --bind 0.0.0.0:8000 ojusomap.wsgi"
|
2018-03-31 10:05:09 +00:00
|
|
|
|
2017-05-20 23:52:01 +00:00
|
|
|
db:
|
2017-10-08 20:24:18 +00:00
|
|
|
restart: always
|
2017-05-20 23:52:01 +00:00
|
|
|
image: mdillon/postgis:9.6-alpine
|
2017-10-08 20:24:18 +00:00
|
|
|
networks:
|
|
|
|
- web
|
2017-05-20 23:52:01 +00:00
|
|
|
volumes:
|
|
|
|
- /containers/db:/var/lib/postgresql/data
|
|
|
|
- ./support/postgres/docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
|
|
|
|
ports:
|
|
|
|
- "127.0.0.1:5432:5432"
|
|
|
|
env_file:
|
|
|
|
- ./environment
|
2018-03-31 10:05:09 +00:00
|
|
|
|
2017-05-20 23:52:01 +00:00
|
|
|
weblate:
|
|
|
|
image: weblate/weblate
|
|
|
|
links:
|
|
|
|
- db:database
|
|
|
|
- cache
|
2017-10-08 20:24:18 +00:00
|
|
|
networks:
|
|
|
|
- web
|
|
|
|
labels:
|
|
|
|
- "traefik.backend=weblate"
|
|
|
|
- "traefik.frontend.rule=Host:translate.ojuso.org"
|
|
|
|
- "traefik.frontend.priority=5"
|
|
|
|
- "traefik.frontend.passHostHeader=true"
|
2017-05-20 23:52:01 +00:00
|
|
|
volumes:
|
|
|
|
- weblate-data:/app/data
|
|
|
|
env_file:
|
|
|
|
- ./environment
|
|
|
|
environment:
|
|
|
|
- "POSTGRES_USER=weblate"
|
|
|
|
- "POSTGRES_DATABASE=weblate"
|
2018-04-23 05:57:28 +00:00
|
|
|
- "MEMCACHED_HOST=cache"
|
2017-05-20 23:52:01 +00:00
|
|
|
restart: always
|
2018-03-31 10:05:09 +00:00
|
|
|
|
2017-05-20 23:52:01 +00:00
|
|
|
cache:
|
|
|
|
image: memcached:1.4
|
|
|
|
restart: always
|
2017-10-08 20:24:18 +00:00
|
|
|
networks:
|
|
|
|
- web
|
|
|
|
|
|
|
|
weblate_static:
|
|
|
|
image: nginx:alpine
|
|
|
|
restart: always
|
|
|
|
depends_on:
|
|
|
|
- weblate
|
|
|
|
labels:
|
|
|
|
- "traefik.backend=weblate_static"
|
|
|
|
- "traefik.frontend.rule=Host:translate.ojuso.org;PathPrefixStrip:/static/"
|
|
|
|
- "traefik.frontend.priority=10"
|
|
|
|
networks:
|
|
|
|
- web
|
|
|
|
volumes:
|
|
|
|
- type: bind
|
|
|
|
source: /var/lib/docker/volumes/ojusomap_weblate-data/_data/static
|
|
|
|
target: /usr/share/nginx/html
|
|
|
|
read_only: true
|
|
|
|
|
|
|
|
networks:
|
|
|
|
web:
|
|
|
|
external:
|
|
|
|
name: traefik_webgateway
|
2017-05-20 23:52:01 +00:00
|
|
|
|
|
|
|
volumes:
|
|
|
|
weblate-data:
|
2017-10-08 20:24:18 +00:00
|
|
|
weblate-static:
|