From 8545504b43b19471897b436e37ad853d04d6040e Mon Sep 17 00:00:00 2001 From: briskt <3172830+briskt@users.noreply.github.com> Date: Mon, 18 Mar 2024 12:59:52 -0600 Subject: [PATCH] add back the db-users.sql file that was accidentally deleted in de785e --- terraform/020-database/db-users.sql | 34 +++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 terraform/020-database/db-users.sql diff --git a/terraform/020-database/db-users.sql b/terraform/020-database/db-users.sql new file mode 100644 index 00000000..04ed6f33 --- /dev/null +++ b/terraform/020-database/db-users.sql @@ -0,0 +1,34 @@ +Once phpmyadmin is running at -pma., execute the following +sql statements to create users and databases ... + +CREATE USER 'idbroker'@'%' IDENTIFIED BY '${idbroker_pass}'; +GRANT USAGE ON *.* TO 'idbroker'@'%' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 0 + MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0; +CREATE DATABASE IF NOT EXISTS `idbroker`;GRANT SELECT, INSERT, UPDATE, DELETE, + CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, CREATE VIEW, EVENT, + TRIGGER, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, + EXECUTE ON `idbroker`.* TO 'idbroker'@'%'; + +CREATE USER 'pwmanager'@'%' IDENTIFIED BY '${pwmanager_pass}'; +GRANT USAGE ON *.* TO 'pwmanager'@'%' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 0 + MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0; +CREATE DATABASE IF NOT EXISTS `pwmanager`;GRANT SELECT, INSERT, UPDATE, DELETE, + CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, CREATE VIEW, EVENT, + TRIGGER, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, + EXECUTE ON `pwmanager`.* TO 'pwmanager'@'%'; + +CREATE USER 'ssp'@'%' IDENTIFIED BY '${ssp_pass}'; +GRANT USAGE ON *.* TO 'ssp'@'%' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 0 + MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0; +CREATE DATABASE IF NOT EXISTS `ssp`;GRANT SELECT, INSERT, UPDATE, DELETE, + CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, CREATE VIEW, EVENT, + TRIGGER, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, + EXECUTE ON `ssp`.* TO 'ssp'@'%'; + +CREATE USER 'emailservice'@'%' IDENTIFIED BY '${emailservice_pass}'; +GRANT USAGE ON *.* TO 'emailservice'@'%' REQUIRE NONE WITH MAX_QUERIES_PER_HOUR 0 + MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0; +CREATE DATABASE IF NOT EXISTS `emailservice`;GRANT SELECT, INSERT, UPDATE, DELETE, + CREATE, DROP, INDEX, ALTER, CREATE TEMPORARY TABLES, CREATE VIEW, EVENT, + TRIGGER, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, + EXECUTE ON `emailservice`.* TO 'emailservice'@'%';