ansible/roles/docker/files/composefiles/nginx-proxy.yml

50 lines
969 B
YAML
Raw Normal View History

2018-06-24 13:17:35 +00:00
---
version: '3'
services:
2018-06-24 13:17:35 +00:00
nginx-proxy:
image: jwilder/nginx-proxy
container_name: nginx-proxy
networks:
- external_services
2018-06-24 13:17:35 +00:00
ports:
- "80:80"
- "443:443"
2018-06-24 13:17:35 +00:00
volumes:
- conf:/etc/nginx/conf.d
- vhost:/etc/nginx/vhost.d
- html:/usr/share/nginx/html
- dhparam:/etc/nginx/dhparam
- certs:/etc/nginx/certs:ro
2018-06-24 13:17:35 +00:00
- /var/run/docker.sock:/tmp/docker.sock:ro
restart: always
letsencrypt:
image: jrcs/letsencrypt-nginx-proxy-companion
container_name: nginx-proxy-le
depends_on:
- nginx-proxy
volumes:
- vhost:/etc/nginx/vhost.d
- html:/usr/share/nginx/html
- dhparam:/etc/nginx/dhparam:ro
- certs:/etc/nginx/certs
- /var/run/docker.sock:/var/run/docker.sock:ro
environment:
- NGINX_PROXY_CONTAINER=nginx-proxy
restart: always
volumes:
conf:
vhost:
html:
dhparam:
certs:
2018-06-24 13:17:35 +00:00
networks:
external_services:
2018-06-24 13:17:35 +00:00
external: true