Permalink
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
98 lines (89 sloc) 2.59 KB
version: "3"
services:
database:
image: postgres:10-alpine # https://hub.docker.com/_/postgres/
env_file:
- etc/env/postgres.env
volumes:
- ./etc/postgres/initdb.d:/docker-entrypoint-initdb.d
- pgdata:/var/lib/postgresql/data
click-migration:
image: kamilsk/click:1.x # https://hub.docker.com/r/kamilsk/click/
command: [ "migrate", "up" ]
depends_on:
- database
env_file:
- etc/env/click.env
restart: on-failure
click:
image: kamilsk/click:1.x
command: [ "run", "--with-profiler", "--with-monitoring" ]
depends_on:
- click-migration
env_file:
- etc/env/click.env
forma-migration:
image: kamilsk/form-api:1.x # https://hub.docker.com/r/kamilsk/form-api/
command: [ "migrate", "up" ]
depends_on:
- database
env_file:
- etc/env/forma.env
restart: on-failure
forma:
image: kamilsk/form-api:1.x
command: [ "run", "--with-profiler", "--with-monitoring" ]
depends_on:
- forma-migration
env_file:
- etc/env/forma.env
hugo:
image: kamilsk/hugo:latest # https://hub.docker.com/r/kamilsk/hugo/
env_file:
- etc/env/hugo.env
volumes:
- ./site:/usr/share/site
passport-migration:
image: kamilsk/passport:1.x # https://hub.docker.com/r/kamilsk/passport/
command: [ "migrate", "up" ]
depends_on:
- database
env_file:
- etc/env/passport.env
restart: on-failure
passport:
image: kamilsk/passport:1.x
command: [ "run", "--with-profiling", "--with-monitoring" ]
depends_on:
- passport-migration
env_file:
- etc/env/passport.env
volumes:
- static_passport:/usr/share/passport
server:
image: kamilsk/nginx:1.x # https://hub.docker.com/r/kamilsk/nginx/
depends_on:
- click
- forma
- hugo
- passport
entrypoint: |
/bin/bash -c "echo $$BASIC_USER:`(echo $$BASIC_PASS | openssl passwd -crypt -stdin -noverify)` >> /etc/nginx/.htpasswd \
&& /entrypoint.sh 127.0.0.1.xip.io \
click.127.0.0.1.xip.io \
forma.127.0.0.1.xip.io \
passport.127.0.0.1.xip.io"
env_file:
- etc/env/balancer.env
ports:
- ${HUGS_HTTP_PORT}:80
- ${HUGS_HTTPS_PORT}:443
volumes:
- ./etc/nginx/ssl:/etc/nginx/ssl:ro
- ./etc/nginx/conf.d:/etc/nginx/sites-available:ro
- letsencrypt:/etc/letsencrypt
- static_passport:/usr/share/nginx/html/assets
volumes:
pgdata: { driver: local }
letsencrypt: { driver: local }
static_passport: { driver: local }