Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
docker-compose file with user defined network, data container, rabbitmq, mysql
version: '2'
services:
rmq:
container_name: rm-rabbitmq
image: rabbitmq:3.6
networks:
- rmnet
data:
image: alpine:latest
command: /bin/true
volumes:
- "$DATA_PHOTOS:/data/photos"
- "$DATA_RESPONSES:/data/responses"
mysql:
container_name: rm-mysql
image: mysql:5.7
networks:
- rmnet
environment:
MYSQL_ROOT_PASSWORD: root
volumes:
- logvolume01:/var/log
imger:
container_name: rm-imger
build: ./imger
working_dir: /prod
command: ./imger --config config.imger.json
networks:
- rmnet
volumes:
- "$DEPLOY:/prod:ro"
- logvolume01:/var/log
depends_on:
- mysql
volumes_from:
- data
grpc:
container_name: rm-grpc
image: ubuntu:15.10
working_dir: /prod
command: ./grpc --config config.grpc.json
networks:
- rmnet
depends_on:
- mysql
- rmq
- imger
volumes:
- "$DEPLOY:/prod:ro"
- logvolume01:/var/log
- /etc/letsencrypt:/etc/letsencrypt:ro
volumes_from:
- data
volumes:
logvolume01: {}
networks:
rmnet:
driver: bridge
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment