Повторение материала и проверка знаний работников по направлениям деятельности
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
552 B

1 month ago
#!/bin/bash
set -e
3 weeks ago
# подключаемся от пользователя exam к базе exam
1 month ago
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
CREATE USER moodle WITH PASSWORD 'moodle';
CREATE DATABASE moodle;
GRANT ALL PRIVILEGES ON DATABASE moodle TO moodle;
3 weeks ago
EOSQL
# \c moodle
# подключаемся от пользователя exam к базе moodle
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "moodle" <<-EOSQL
GRANT ALL PRIVILEGES ON SCHEMA public TO moodle;
1 month ago
EOSQL