Create postgres user to avoid fatal warning

This commit is contained in:
Sandro Jäckel 2020-06-04 08:10:30 +02:00
parent 7b2b19b4ba
commit e16d951da0
No known key found for this signature in database
GPG Key ID: 3AF5A43A3EECC2E5
1 changed files with 4 additions and 0 deletions

View File

@ -1,6 +1,10 @@
#!/bin/sh
set -eou pipefail
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" <<-EOSQL
CREATE USER postgres;
EOSQL
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" < config/sql/channels.sql
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" < config/sql/videos.sql
psql -v ON_ERROR_STOP=1 --username "$POSTGRES_USER" --dbname "$POSTGRES_DB" < config/sql/channel_videos.sql