Skip to content

Instantly share code, notes, and snippets.

@Pierre-Gilles
Created October 14, 2018 09:02
Show Gist options
  • Save Pierre-Gilles/2d3f6a7ca7fe4531730856fe7485a8a1 to your computer and use it in GitHub Desktop.
Save Pierre-Gilles/2d3f6a7ca7fe4531730856fe7485a8a1 to your computer and use it in GitHub Desktop.
Mailtrain docker compose with HTTPS
version: '2'
services:
nginx-proxy:
image: jwilder/nginx-proxy:alpine
restart: always
ports:
- "80:80"
- "443:443"
volumes:
- /root/certs:/etc/nginx/certs:ro
- /etc/nginx/vhost.d
- /usr/share/nginx/html
- /var/run/docker.sock:/tmp/docker.sock:ro
lets-encrypt-companion:
image: jrcs/letsencrypt-nginx-proxy-companion
restart: always
volumes:
- /root/certs:/etc/nginx/certs:rw
- /var/run/docker.sock:/var/run/docker.sock:ro
volumes_from:
- nginx-proxy
mysql:
restart: always
redis:
restart: always
mailtrain:
build: ./
# volumes:
# - ./:/app
expose:
- "3000"
restart: always
environment:
- VIRTUAL_HOST=the-domain-you-want-for-your-mailtrain
- LETSENCRYPT_HOST=the-domain-you-want-for-your-mailtrain
- LETSENCRYPT_EMAIL=your-email
@catbadger
Copy link

Lacks the other 2 exposed ports. I needed to use swag proxy.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment