aboutsummaryrefslogtreecommitdiff
path: root/ansible/roles/mw-backend/files/bin/mw-dump-db
diff options
context:
space:
mode:
Diffstat (limited to 'ansible/roles/mw-backend/files/bin/mw-dump-db')
-rw-r--r--ansible/roles/mw-backend/files/bin/mw-dump-db3
1 files changed, 2 insertions, 1 deletions
diff --git a/ansible/roles/mw-backend/files/bin/mw-dump-db b/ansible/roles/mw-backend/files/bin/mw-dump-db
index 0a82059..5a6699a 100644
--- a/ansible/roles/mw-backend/files/bin/mw-dump-db
+++ b/ansible/roles/mw-backend/files/bin/mw-dump-db
@@ -8,4 +8,5 @@ export PGUSER=$(sed -n 's,^.wgDBuser.*"\([^"]*\)".*,\1,p' /etc/mediawiki/LocalSe
export PGPASSWORD=$(sed -n 's,^.wgDBpassword.*"\([^"]*\)".*,\1,p' /etc/mediawiki/LocalSettings.php)
export PGPORT=$(sed -n 's,^.wgDBport.*"\([^"]*\)".*,\1,p' /etc/mediawiki/LocalSettings.php)
-exec pg_dump -b --format directory -f /mediawiki-backup/db
+rm -rf /opt/mediawiki/backup/db
+exec pg_dump -b --format directory -f /opt/mediawiki/backup/db