ninedocker/services/15-mariadb/volume/nine/init.sh

3 lines
190 B
Bash
Raw Normal View History

2024-07-24 16:11:40 +02:00
#!/bin/bash
mariadb -u root -p$MARIADB_ROOT_PASSWORD -e "CREATE DATABASE IF NOT EXISTS $1;"
mariadb -u root -p$MARIADB_ROOT_PASSWORD -e "GRANT ALL PRIVILEGES ON $1.* TO '$MARIADB_USER'@'%';"