summaryrefslogtreecommitdiffstats
path: root/bin/exit_hook.service-reload.sh
diff options
context:
space:
mode:
Diffstat (limited to 'bin/exit_hook.service-reload.sh')
-rwxr-xr-xbin/exit_hook.service-reload.sh13
1 files changed, 13 insertions, 0 deletions
diff --git a/bin/exit_hook.service-reload.sh b/bin/exit_hook.service-reload.sh
new file mode 100755
index 0000000..d434b71
--- /dev/null
+++ b/bin/exit_hook.service-reload.sh
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+echo " + Reloading services..."
+
+for PACKAGE in apache2 haproxy postgresql
+do
+ if /usr/sbin/service ${PACKAGE} status > /dev/null 2>&1
+ then
+ echo -n " + ${PACKAGE}:"
+ /usr/sbin/service ${PACKAGE} reload
+ echo " done."
+ fi
+done