summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--debian/open-infrastructure-dehydrated-tools.config2
-rwxr-xr-xdebian/open-infrastructure-dehydrated-tools.postinst7
2 files changed, 7 insertions, 2 deletions
diff --git a/debian/open-infrastructure-dehydrated-tools.config b/debian/open-infrastructure-dehydrated-tools.config
index d2e8cd2..dfccb77 100644
--- a/debian/open-infrastructure-dehydrated-tools.config
+++ b/debian/open-infrastructure-dehydrated-tools.config
@@ -42,7 +42,7 @@ db_go
if [ -e /usr/share/dehydrated/hooks ]
then
HOOKS_CHOICES="$(cd /usr/share/dehydrated/hooks && find -maxdepth 1 -not -type d -printf '%P\n' | sort)"
- db_subst open-infrastructure-dehydrated-tools/hooks HOOKS_CHOICES "$(echo ${HOOKS_CHOICES} | sed -e 's| |, |g')"
+ db_subst open-infrastructure-dehydrated-tools/hooks HOOKS_CHOICES "ALL, $(echo ${HOOKS_CHOICES} | sed -e 's| |, |g')"
db_settitle open-infrastructure-dehydrated-tools/title
db_input low open-infrastructure-dehydrated-tools/hooks || true
diff --git a/debian/open-infrastructure-dehydrated-tools.postinst b/debian/open-infrastructure-dehydrated-tools.postinst
index 116223f..fdf39dc 100755
--- a/debian/open-infrastructure-dehydrated-tools.postinst
+++ b/debian/open-infrastructure-dehydrated-tools.postinst
@@ -116,9 +116,14 @@ case "${1}" in
HOOKS="$(echo ${HOOKS} | sed -e 's|,| |g')"
+ if echo "${HOOKS}" | grep -qs "ALL"
+ then
+ HOOKS="$(cd /usr/share/dehydrated/hooks && find -maxdepth 1 -not -type d -printf '%P\n' | sort)"
+ fi
+
for HOOK in ${HOOKS}
do
- if [ ! -e "/etc/dehydrated/hook.d/${HOOK}" ]
+ if [ ! -e "/etc/dehydrated/hook.d/${HOOK}" ] && [ -e "/usr/share/dehydrated/hooks/${HOOK}" ]
then
ln -sf "/usr/share/dehydrated/hooks/${HOOK}" "/etc/dehydrated/hook.d/${HOOK}"
fi