Add galera

This commit is contained in:
MrLetsplay 2023-05-21 16:21:56 +02:00
parent 4d85849aa7
commit 263824041e
4 changed files with 52 additions and 0 deletions

9
galera/bootstrap/.env Normal file
View File

@ -0,0 +1,9 @@
MARIADB_GALERA_CLUSTER_NAME=my_galera
MARIADB_GALERA_MARIABACKUP_USER=my_mariabackup_user
MARIADB_GALERA_MARIABACKUP_PASSWORD=my_mariabackup_password
MARIADB_ROOT_PASSWORD=my_root_password
MARIADB_USER=my_user
MARIADB_PASSWORD=my_password
MARIADB_DATABASE=my_database
MARIADB_REPLICATION_USER=my_replication_user
MARIADB_REPLICATION_PASSWORD=my_replication_password

View File

@ -0,0 +1,19 @@
services:
galera-bootstrap:
image: bitnami/mariadb-galera:latest
ports:
- 3306:3306
- 4444:4444
- 4567:4567
- 4568:4568
environment:
- MARIADB_GALERA_CLUSTER_BOOTSTRAP=yes
- MARIADB_GALERA_CLUSTER_NAME=${MARIADB_GALERA_CLUSTER_NAME}
- MARIADB_GALERA_MARIABACKUP_USER=${MARIADB_GALERA_MARIABACKUP_USER}
- MARIADB_GALERA_MARIABACKUP_PASSWORD=${MARIADB_GALERA_MARIABACKUP_PASSWORD}
- MARIADB_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD}
- MARIADB_USER=${MARIADB_USER}
- MARIADB_PASSWORD=${MARIADB_PASSWORD}
- MARIADB_DATABASE=${MARIADB_DATABASE}
- MARIADB_REPLICATION_USER=${MARIADB_REPLICATION_USER}
- MARIADB_REPLICATION_PASSWORD=${MARIADB_REPLICATION_PASSWORD}

8
galera/default/.env Normal file
View File

@ -0,0 +1,8 @@
MARIADB_GALERA_CLUSTER_NAME=my_galera
MARIADB_GALERA_CLUSTER_ADDRESS=gcomm://galera-1:4567
MARIADB_GALERA_MARIABACKUP_USER=my_mariabackup_user
MARIADB_GALERA_MARIABACKUP_PASSWORD=my_mariabackup_password
MARIADB_ROOT_PASSWORD=my_root_password
MARIADB_REPLICATION_USER=my_replication_user
MARIADB_REPLICATION_PASSWORD=my_replication_password

View File

@ -0,0 +1,16 @@
services:
galera:
image: bitnami/mariadb-galera:latest
ports:
- 3306:3306
- 4444:4444
- 4567:4567
- 4568:4568
environment:
- MARIADB_GALERA_CLUSTER_NAME=${MARIADB_GALERA_CLUSTER_NAME}
- MARIADB_GALERA_CLUSTER_ADDRESS=${MARIADB_GALERA_CLUSTER_ADDRESS}
- MARIADB_GALERA_MARIABACKUP_USER=${MARIADB_GALERA_MARIABACKUP_USER}
- MARIADB_GALERA_MARIABACKUP_PASSWORD=${MARIADB_GALERA_MARIABACKUP_PASSWORD}
- MARIADB_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD}
- MARIADB_REPLICATION_USER=${MARIADB_REPLICATION_USER}
- MARIADB_REPLICATION_PASSWORD=${MARIADB_REPLICATION_PASSWORD}