You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It throws an error, if the DB does not exist.
Could you please change the line psql postgres -U musicbrainz -h db -c "DROP DATABASE musicbrainz_db;"; createdb.sh "$@"
into psql postgres -U musicbrainz -h db -c "DROP DATABASE IF EXISTS musicbrainz_db;"; createdb.sh "$@"
according to https://www.postgresql.org/docs/current/sql-dropdatabase.html
This would allow to use recreatedb.sh in any case.
If the DB does not exist, it does not stop working with an error:
ERRROR: database "musicbrainz_db" does not exist
ERROR: 1
If the DB does exist, it will be dropped/deleted and then - inside the script createdb.sh - newly created.
The text was updated successfully, but these errors were encountered:
https://github.com/metabrainz/musicbrainz-docker/blob/master/build/musicbrainz/scripts/recreatedb.sh
It throws an error, if the DB does not exist.
Could you please change the line
psql postgres -U musicbrainz -h db -c "DROP DATABASE musicbrainz_db;"; createdb.sh "$@"
into
psql postgres -U musicbrainz -h db -c "DROP DATABASE IF EXISTS musicbrainz_db;"; createdb.sh "$@"
according to https://www.postgresql.org/docs/current/sql-dropdatabase.html
This would allow to use
recreatedb.sh
in any case.If the DB does not exist, it does not stop working with an error:
If the DB does exist, it will be dropped/deleted and then - inside the script createdb.sh - newly created.
The text was updated successfully, but these errors were encountered: