2023-12-14 10:15:17 +01:00
|
|
|
services:
|
|
|
|
mysql-server:
|
|
|
|
image: "${MYSQL_IMAGE}:${MYSQL_IMAGE_TAG}"
|
|
|
|
command:
|
|
|
|
- mysqld
|
2024-05-28 10:10:23 +02:00
|
|
|
- --skip-mysqlx
|
2023-12-14 10:15:17 +01:00
|
|
|
- --character-set-server=utf8mb4
|
|
|
|
- --collation-server=utf8mb4_bin
|
2024-01-18 17:13:10 +01:00
|
|
|
# Only during upgrade from versions prior 6.4 and new installations (schema deployment)
|
|
|
|
- --log_bin_trust_function_creators=1
|
2023-12-14 10:15:17 +01:00
|
|
|
# Use TLS encryption for connections to database
|
|
|
|
# - --require-secure-transport
|
|
|
|
# - --ssl-ca=/run/secrets/root-ca.pem
|
|
|
|
# - --ssl-cert=/run/secrets/server-cert.pem
|
|
|
|
# - --ssl-key=/run/secrets/server-key.pem
|
|
|
|
restart: "${RESTART_POLICY}"
|
2024-05-28 10:10:23 +02:00
|
|
|
attach: false
|
2023-12-14 10:15:17 +01:00
|
|
|
volumes:
|
|
|
|
- ${DATA_DIRECTORY}/var/lib/mysql:/var/lib/mysql:rw
|
2024-01-18 17:13:10 +01:00
|
|
|
- ${ENV_VARS_DIRECTORY}/mysql_init/init_proxy_db.sql:/docker-entrypoint-initdb.d/mysql_init_proxy.sql:ro
|
2023-12-14 10:15:17 +01:00
|
|
|
# - dbsocket:/var/run/mysqld/
|
|
|
|
env_file:
|
|
|
|
- ${ENV_VARS_DIRECTORY}/.env_db_mysql
|
2024-05-28 10:10:23 +02:00
|
|
|
- path: ${ENV_VARS_DIRECTORY}/.env_db_mysql_override
|
|
|
|
required: false
|
2024-01-18 17:13:10 +01:00
|
|
|
environment:
|
|
|
|
- MYSQL_ROOT_PASSWORD_FILE=/run/secrets/MYSQL_ROOT_PASSWORD
|
2023-12-14 10:15:17 +01:00
|
|
|
secrets:
|
|
|
|
- MYSQL_USER
|
|
|
|
- MYSQL_PASSWORD
|
|
|
|
- MYSQL_ROOT_PASSWORD
|
|
|
|
# - server-key.pem
|
|
|
|
# - server-cert.pem
|
|
|
|
# - root-ca.pem
|
|
|
|
stop_grace_period: 1m
|
|
|
|
networks:
|
2024-05-28 10:10:23 +02:00
|
|
|
database:
|
2023-12-14 10:15:17 +01:00
|
|
|
aliases:
|
|
|
|
- mysql-server
|
|
|
|
|
|
|
|
postgres-server:
|
|
|
|
image: "${POSTGRESQL_IMAGE}:${POSTGRESQL_IMAGE_TAG}"
|
|
|
|
# command: -c ssl=on -c ssl_cert_file=/run/secrets/server-cert.pem -c ssl_key_file=/run/secrets/server-key.pem -c ssl_ca_file=/run/secrets/root-ca.pem
|
|
|
|
restart: "${RESTART_POLICY}"
|
2024-05-28 10:10:23 +02:00
|
|
|
attach: false
|
2023-12-14 10:15:17 +01:00
|
|
|
volumes:
|
|
|
|
- ${DATA_DIRECTORY}/var/lib/postgresql/data:/var/lib/postgresql/data:rw
|
|
|
|
- ${ENV_VARS_DIRECTORY}/.ZBX_DB_CA_FILE:/run/secrets/root-ca.pem:ro
|
|
|
|
- ${ENV_VARS_DIRECTORY}/.ZBX_DB_CERT_FILE:/run/secrets/server-cert.pem:ro
|
|
|
|
- ${ENV_VARS_DIRECTORY}/.ZBX_DB_KEY_FILE:/run/secrets/server-key.pem:ro
|
|
|
|
env_file:
|
|
|
|
- ${ENV_VARS_DIRECTORY}/.env_db_pgsql
|
2024-05-28 10:10:23 +02:00
|
|
|
- path: ${ENV_VARS_DIRECTORY}/.env_db_pgsql_override
|
|
|
|
required: false
|
2023-12-14 10:15:17 +01:00
|
|
|
secrets:
|
|
|
|
- POSTGRES_USER
|
|
|
|
- POSTGRES_PASSWORD
|
|
|
|
stop_grace_period: 1m
|
|
|
|
networks:
|
2024-05-28 10:10:23 +02:00
|
|
|
database:
|
2023-12-14 10:15:17 +01:00
|
|
|
aliases:
|
|
|
|
- postgres-server
|
|
|
|
|
|
|
|
db-data-mysql:
|
2024-10-25 11:22:40 +02:00
|
|
|
image: "${BUSYBOX_IMAGE}:${BUSYBOX_IMAGE_TAG}"
|
2023-12-14 10:15:17 +01:00
|
|
|
volumes:
|
|
|
|
- ${DATA_DIRECTORY}/var/lib/mysql:/var/lib/mysql:rw
|
|
|
|
|
|
|
|
db-data-pgsql:
|
2024-10-25 11:22:40 +02:00
|
|
|
image: "${BUSYBOX_IMAGE}:${BUSYBOX_IMAGE_TAG}"
|
2024-05-28 10:10:23 +02:00
|
|
|
attach: false
|
2023-12-14 10:15:17 +01:00
|
|
|
volumes:
|
|
|
|
- ${DATA_DIRECTORY}/var/lib/postgresql/data:/var/lib/postgresql/data:rw
|
|
|
|
|
|
|
|
elasticsearch:
|
|
|
|
image: "${ELASTICSEARCH_IMAGE}:${ELASTICSEARCH_IMAGE_TAG}"
|
|
|
|
restart: "${RESTART_POLICY}"
|
2024-05-28 10:10:23 +02:00
|
|
|
attach: false
|
2023-12-14 10:15:17 +01:00
|
|
|
profiles:
|
2024-06-10 09:32:50 +02:00
|
|
|
- elasticsearch
|
2023-12-14 10:15:17 +01:00
|
|
|
environment:
|
|
|
|
- transport.host=0.0.0.0
|
|
|
|
- discovery.zen.minimum_master_nodes=1
|
|
|
|
networks:
|
2024-05-28 10:10:23 +02:00
|
|
|
database:
|
2023-12-14 10:15:17 +01:00
|
|
|
aliases:
|
|
|
|
- elasticsearch
|