A mysql root password is needed

This commit is contained in:
Janic Voser 2022-10-18 23:38:33 +02:00
parent deb7cdbc35
commit a8db2d5452
2 changed files with 1 additions and 3 deletions

View File

@ -7,7 +7,7 @@
## Database Variables ## Database Variables
db = {} db = {}
#- db['root_pw'] = 'RootPassWord' db['root_pw'] = 'RootPassWord'
db['enabled'] = True db['enabled'] = True
db['user'] = 'DBUser' db['user'] = 'DBUser'
db['user_pw'] = 'DBUserPassWord' db['user_pw'] = 'DBUserPassWord'

View File

@ -7,9 +7,7 @@ services:
image: mariadb:latest image: mariadb:latest
restart: always restart: always
environment: environment:
{%- if db.root_pw is defined %}
MARIADB_ROOT_PASSWORD: {{ db.root_pw }} MARIADB_ROOT_PASSWORD: {{ db.root_pw }}
{%- endif %}
MARIADB_USER: {{ db.user }} MARIADB_USER: {{ db.user }}
MARIADB_PASSWORD: {{ db.user_pw }} MARIADB_PASSWORD: {{ db.user_pw }}
MARIADB_DATABASE: {{ db.db }} MARIADB_DATABASE: {{ db.db }}