refactor(base): common anchor
This commit is contained in:
parent
7b004d7372
commit
6be48129f6
1 changed files with 18 additions and 24 deletions
|
@ -5,44 +5,38 @@ networks:
|
||||||
proxy:
|
proxy:
|
||||||
external: true
|
external: true
|
||||||
|
|
||||||
services:
|
x-common: &common
|
||||||
proxy:
|
|
||||||
build:
|
|
||||||
context: custom/proxy
|
|
||||||
container_name: proxy
|
|
||||||
restart: always
|
restart: always
|
||||||
privileged: true
|
environment:
|
||||||
ports:
|
- DEFAULT_EMAIL=webmaster@faulty.nl
|
||||||
- 80:80
|
- DEFAULT_HOST=home.famslof.nl
|
||||||
- 443:443
|
|
||||||
volumes:
|
volumes:
|
||||||
- /srv/.webcerts:/etc/nginx/certs:rw
|
- /srv/.webcerts:/etc/nginx/certs:rw
|
||||||
- /srv/proxy/config/conf.d:/etc/nginx/conf.d
|
- /srv/proxy/config/conf.d:/etc/nginx/conf.d
|
||||||
- /srv/proxy/other/vhost.d:/etc/nginx/vhost.d
|
- /srv/proxy/other/vhost.d:/etc/nginx/vhost.d
|
||||||
- /srv/proxy/data/html:/usr/share/nginx/html
|
- /srv/proxy/data/html:/usr/share/nginx/html
|
||||||
- /var/run/docker.sock:/tmp/docker.sock
|
- /var/run/docker.sock:/tmp/docker.sock
|
||||||
labels:
|
|
||||||
- com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy=true
|
|
||||||
networks:
|
networks:
|
||||||
proxy:
|
proxy:
|
||||||
|
|
||||||
|
services:
|
||||||
|
proxy:
|
||||||
|
<<: *common
|
||||||
|
build:
|
||||||
|
context: custom/proxy
|
||||||
|
container_name: proxy
|
||||||
|
privileged: true
|
||||||
|
ports:
|
||||||
|
- 80:80
|
||||||
|
- 443:443
|
||||||
|
labels:
|
||||||
|
- com.github.jrcs.letsencrypt_nginx_proxy_companion.nginx_proxy=true
|
||||||
|
|
||||||
letsencrypt:
|
letsencrypt:
|
||||||
|
<<: *common
|
||||||
container_name: letsencrypt
|
container_name: letsencrypt
|
||||||
restart: always
|
|
||||||
image: nginxproxy/acme-companion
|
image: nginxproxy/acme-companion
|
||||||
depends_on:
|
depends_on:
|
||||||
- proxy
|
- proxy
|
||||||
volumes:
|
|
||||||
- /srv/.webcerts:/etc/nginx/certs:rw
|
|
||||||
- /srv/proxy/config/conf.d:/etc/nginx/conf.d
|
|
||||||
- /srv/proxy/other/vhost.d:/etc/nginx/vhost.d
|
|
||||||
- /srv/proxy/data/html:/usr/share/nginx/html
|
|
||||||
- /var/run/docker.sock:/var/run/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
- DEFAULT_EMAIL=webmaster@faulty.nl
|
|
||||||
- DEFAULT_HOST=home.famslof.nl
|
|
||||||
#- NGINX_DOCKER_GEN_CONTAINER=proxy
|
|
||||||
# profiles:
|
|
||||||
# - production
|
|
||||||
networks:
|
|
||||||
proxy:
|
|
Reference in a new issue