Skip to content

Instantly share code, notes, and snippets.

@valeryan
Last active May 1, 2018
Embed
What would you like to do?
Using docker-compose to run a mineos server
version: "2"
services:
nginx-proxy:
image: jwilder/nginx-proxy
container_name: nginx-proxy
ports:
- "80:80"
- "443:443"
volumes:
- ./proxy/conf.d:/etc/nginx/conf.d
- ./proxy/vhost.d:/etc/nginx/vhost.d
- ./proxy/html:/usr/share/nginx/html
- ./proxy/certs:/etc/nginx/certs:ro
- /var/run/docker.sock:/tmp/docker.sock:ro
networks:
- proxy-tier
letsencrypt-nginx-proxy-companion:
image: jrcs/letsencrypt-nginx-proxy-companion
container_name: letsencrypt-nginx-proxy-companion
volumes_from:
- nginx-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- ./proxy/certs:/etc/nginx/certs:rw
mineos:
image: hexparrot/mineos:node-wily
container_name: mineos
volumes:
- ./minecraft:/var/games/minecraft
ports:
- "25565:25565"
- "8443:8443"
environment:
- VIRTUAL_HOST=mineos.example.com
- VIRTUAL_NETWORK=nginx-proxy
- VIRTUAL_PROTO=https
- VIRTUAL_PORT=8443
- LETSENCRYPT_HOST=mineos.example.com
- LETSENCRYPT_EMAIL=email@example.com
- USER_NAME=mc
- USER_PASSWORD=password
networks:
- proxy-tier
networks:
proxy-tier:
driver: bridge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment