version: '3'
networks:
proxy:
- external:
- name: proxy
+ external: true
services:
- nginx:
- image: nginx:1.17
- restart: on-failure
- deploy:
- restart_policy:
- condition: on-failure
- delay: 5s
- max_attempts: 5
- window: 10s
+ web:
+ image: nginx:1.27-alpine
volumes:
- - ./nginx.conf:/etc/nginx/nginx.conf
+ - /etc/letsencrypt/:/etc/letsencrypt/
+ - ./conf.d/:/etc/nginx/conf.d/
environment:
- NGINX_HOST=purplebirdman.com
- - NGINX_PORT=80
+ - NGINX_PORT=443
ports:
- - 80:80
- 443:443
networks:
- proxy