cde3d8cd3c
MySQL/MariaDB has a startup time so adding a depends_on and reorganization may fix a few things
48 lines
1.1 KiB
YAML
48 lines
1.1 KiB
YAML
version: '3.4'
|
|
|
|
networks:
|
|
lbrynet:
|
|
external: true
|
|
|
|
services:
|
|
#############
|
|
## MariaDB ##
|
|
#############
|
|
## https://hub.docker.com/r/_/mariadb/
|
|
mysql:
|
|
image: mariadb
|
|
restart: always
|
|
networks:
|
|
lbrynet:
|
|
ipv4_address: 10.10.0.10
|
|
aliases:
|
|
- mysql
|
|
environment:
|
|
## These variables are stored in the .env file next to this docker-compose.yml file.
|
|
## I will include a default .env file and .gitignore the ".env" pattern so you should be able to just git pull in the future if you need to.
|
|
MYSQL_SERVER: ${MYSQL_SERVER:-10.10.0.10}
|
|
MYSQL_USER: ${MYSQL_USER:-changeme}
|
|
MYSQL_PASSWORD: ${MYSQL_PASSWORD:-changeme}
|
|
MYSQL_DATABASE: ${MYSQL_DATABASE:-chainquery}
|
|
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD:-changeme}
|
|
expose:
|
|
- 3306
|
|
volumes:
|
|
- ./data/db:/var/lib/mysql
|
|
|
|
################
|
|
## Chainquery ##
|
|
################
|
|
chainquery:
|
|
build: .
|
|
restart: always
|
|
networks:
|
|
lbrynet:
|
|
ipv4_address: 10.10.0.2
|
|
labels:
|
|
- "traefik.expose=false"
|
|
expose:
|
|
- 6300
|
|
- 3306
|
|
depends_on:
|
|
- mysql
|