You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
70 lines
1.4 KiB
YAML
70 lines
1.4 KiB
YAML
6 years ago
|
version: '3.6'
|
||
|
|
||
|
services:
|
||
|
|
||
|
cms:
|
||
|
image: androiddrew/datasketch:latest
|
||
|
deploy:
|
||
|
replicas: 1
|
||
|
restart_policy:
|
||
|
condition: on-failure
|
||
|
ports:
|
||
|
- 8000:8000
|
||
|
secrets:
|
||
|
- datasketch_key
|
||
|
- pg_passwd_datasketch
|
||
|
environment:
|
||
|
- DJANGO_SETTINGS_MODULE=cms.settings.production
|
||
|
- DB_HOST=db
|
||
|
- DB_USER=datasketch
|
||
|
volumes:
|
||
|
- datasketch-media-vol:/code/media
|
||
|
depends_on:
|
||
|
- db
|
||
|
networks:
|
||
|
- datasketch_net
|
||
|
|
||
|
db:
|
||
|
image: postgres:10.5-alpine
|
||
|
deploy:
|
||
|
replicas: 1
|
||
|
restart_policy:
|
||
|
condition: on-failure
|
||
|
# Docker secrets for postgres are referenced by /run/secrets/<secret_name>
|
||
|
secrets:
|
||
|
- pg_passwd_datasketch
|
||
|
environment:
|
||
|
- POSTGRES_USER=datasketch
|
||
|
- POSTGRES_PASSWORD_FILE=/run/secrets/pg_passwd_datasketch
|
||
|
- POSTGRES_DB=datasketch
|
||
|
expose:
|
||
|
- 5432
|
||
|
volumes:
|
||
|
- datasketch-db-vol:/var/lib/postgresql/data
|
||
|
networks:
|
||
|
- datasketch_net
|
||
|
|
||
|
|
||
|
networks:
|
||
|
datasketch_net:
|
||
|
driver: overlay
|
||
|
|
||
|
volumes:
|
||
|
datasketch-db-vol:
|
||
|
driver: local
|
||
|
driver_opts:
|
||
|
type: nfs
|
||
|
o: addr=nas1.androiddrew.com,rw
|
||
|
device: ":/volume1/expanse/datasketch_pg_data"
|
||
|
datasketch-media-vol:
|
||
|
driver: local
|
||
|
driver_opts:
|
||
|
type: nfs
|
||
|
o: addr=nas1.androiddrew.com,rw
|
||
|
device: ":/volume1/expanse/datasketch_media"
|
||
|
|
||
|
secrets:
|
||
|
pg_passwd_datasketch:
|
||
|
external: true
|
||
|
datasketch_key:
|
||
|
external: true
|