1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mastodon_ynh.git synced 2024-09-03 19:46:02 +02:00

[fix] PG restore

This commit is contained in:
nemsia 2017-04-26 16:12:34 +02:00 committed by GitHub
parent ed08bd31ad
commit 4f7830b595

View file

@ -90,7 +90,7 @@ sudo cp $YNH_APP_BACKUP_DIR/mastodon_db.sql $final_path
ynh_psql_create_db_without_password "$app"
sudo systemctl restart postgresql
sudo su - postgres <<COMMANDS
pg_dump --role=mastodon -U postgres --no-password mastodon < $final_path/mastodon_db.sql
pg_restore --role=mastodon -U postgres --no-password < $final_path/mastodon_db.sql
COMMANDS
# Delete dump after restore