Adding common Mariadb stack.

This commit is contained in:
Alexey Skobkin 2019-10-27 02:38:01 +03:00
parent d6c3f3883d
commit aa7ad2ed64
No known key found for this signature in database
GPG key ID: 5D5CEF6F221278E7
2 changed files with 25 additions and 0 deletions

2
mariadb-common/.env.dist Normal file
View file

@ -0,0 +1,2 @@
MYSQL_ROOT_PASSWORD=password
COMMON_DATABASE_NETWORK=database-net

View file

@ -0,0 +1,23 @@
version: '3.7'
services:
mariadb-common:
image: mariadb:10
container_name: mariadb-common
env_file: .env
networks:
- db-network
ports:
- "127.0.0.1:3306:3306/tcp"
volumes:
# Database files
- mariadb-data:/var/lib/mysql
restart: unless-stopped
volumes:
mariadb-data:
networks:
db-network:
name: "${COMMON_DATABASE_NETWORK:-database-network}"
external: true