diff --git a/docker-compose.yml b/docker-compose.yml index 2bbf9b7..333df69 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -25,6 +25,10 @@ x-wordpress-configuration-env: &wordpress-configuration-env networks: default: +secrets: + database_root_password: + file: ./.secrets/database_root_password.txt + services: wordpress: image: ghcr.io/n0rthernl1ghts/wordpress:6.5.3 @@ -106,10 +110,12 @@ services: MARIADB_INIT_DATABASES: wordpress MARIADB_INIT_USERS: wordpress MARIADB_PASSWORD: wordpress # CHANGE THIS! - MARIADB_ROOT_PASSWORD: 'super-secure-root-password123' # CHANGE THIS! + FILE__MARIADB_ROOT_PASSWORD: /run/secrets/database_root_password FORCE_CONFIG_OVERWRITE: 1 volumes: - ./data/database/config:/config - ./data/database/data:/var/lib/mysql + secrets: + - database_root_password networks: default: