75 lines
1.9 KiB
YAML
75 lines
1.9 KiB
YAML
version: '3.4'
|
|
|
|
networks:
|
|
traefik:
|
|
external: true
|
|
|
|
services:
|
|
###########
|
|
## MYSQL ##
|
|
###########
|
|
## MariaDB is currently not supported and neither is later versions of MySQL this may change.
|
|
## https://hub.docker.com/r/_/mariadb/
|
|
mysql:
|
|
image: mysql:5.7.23
|
|
restart: always
|
|
networks:
|
|
traefik:
|
|
ipv4_address: 10.5.1.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.5.1.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
|
|
- ./my.cnf:/etc/mysql/conf.d/chainquery-optimizations.cnf
|
|
|
|
#######################
|
|
## Adminer container ##
|
|
#######################
|
|
adminer:
|
|
image: adminer
|
|
# restart: always
|
|
links:
|
|
- "mysql:database"
|
|
depends_on:
|
|
- mysql
|
|
labels:
|
|
# https://docs.traefik.io/user-guide/docker-and-lets-encrypt/
|
|
- "traefik.backend=adminer"
|
|
- "traefik.docker.network=lbrynet"
|
|
- "traefik.frontend.rule=Host:adminer.lbry-demo.nixc.us"
|
|
- "traefik.expose=true"
|
|
- "traefik.port=8080"
|
|
# healthcheck:
|
|
# test: ["CMD", "curl", "--fail", "http://localhost:8080/", "||", "exit", "1"]
|
|
networks:
|
|
traefik:
|
|
ipv4_address: 10.5.1.19
|
|
aliases:
|
|
- adminer
|
|
|
|
################
|
|
## Chainquery ##
|
|
################
|
|
chainquery:
|
|
build: .
|
|
restart: always
|
|
networks:
|
|
traefik:
|
|
ipv4_address: 10.5.1.2
|
|
labels:
|
|
- "traefik.expose=false"
|
|
expose:
|
|
- 6300
|
|
- 3306
|
|
depends_on:
|
|
- mysql
|