From: Nathan Angelacos <nangel@tetrasec.net>
add a "purge" command - delete the temporary database backup
---
main/postgresql/pg-restore.initd | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/main/postgresql/pg-restore.initd b/main/postgresql/pg-restore.initd
index 91c69d1..13462fe 100644
--- a/main/postgresql/pg-restore.initd
+++ b/main/postgresql/pg-restore.initd
@@ -2,7 +2,7 @@
. /etc/conf.d/postgresql
-opts="${opts} dump restore"
+opts="${opts} dump restore purge"
depend() {
need postgresql
@@ -27,6 +27,13 @@ dump() {
eend $?
}
+purge() {
+ yesno "$PGDUMP" && return 0
+ ebegin "Removing temporary $PGDUMP PostgreSQL backup"
+ rm -f "$PGDUMP"
+ eend $?
+}
+
start() {
restore
}
--
1.7.6
---
Unsubscribe: alpine-devel+unsubscribe@lists.alpinelinux.org
Help: alpine-devel+help@lists.alpinelinux.org
---