ottertune/docker/docker-compose.yml

89 lines
2.0 KiB
YAML
Raw Normal View History

2019-08-23 08:47:19 -07:00
version: "3"
services:
base:
build:
context: ../
dockerfile: ./docker/Dockerfile.base-ubuntu-18.04
image: ottertune-base
container_name: ottertune-base
labels:
NAME: "ottertune-base"
web:
build:
context: ../
dockerfile: ./docker/Dockerfile
image: ottertune
container_name: ottertune
expose:
- "8000"
ports:
- "8000:8000"
links:
- mysql
- rabbitmq
depends_on:
- base
- mysql
- rabbitmq
environment:
DEBUG: 'True'
ADMIN_PASSWORD: 'changeme'
ADMIN_EMAIL: 'admin@example.com'
MYSQL_USER: 'root'
MYSQL_PASSWORD: 'ottertune'
MYSQL_HOST: 'mysql'
MAX_DB_CONN_ATTEMPTS: 15
labels:
NAME: "ottertune"
volumes:
- media_data:/app/server/website/media
networks:
- ottertune-net
mysql:
image: mysql:5.7
container_name: mysql
restart: always
environment:
MYSQL_ROOT_PASSWORD: 'ottertune'
MYSQL_PASSWORD: 'ottertune'
MYSQL_DATABASE: 'ottertune'
expose:
- "3306"
ports:
- "3306:3306"
labels:
NAME: "mysql"
volumes:
- mysql_data:/var/lib/mysql
networks:
- ottertune-net
rabbitmq:
image: "rabbitmq:3-management"
container_name: rabbitmq
restart: always
hostname: "rabbitmq"
environment:
RABBITMQ_DEFAULT_USER: "guest"
RABBITMQ_DEFAULT_PASS: "guest"
RABBITMQ_DEFAULT_VHOST: "/"
expose:
- "15672"
- "5672"
ports:
- "15672:15672"
- "5672:5672"
labels:
NAME: "rabbitmq"
networks:
- ottertune-net
volumes:
mysql_data:
media_data:
networks:
ottertune-net:
driver: bridge