summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@open-infrastructure.net>2022-11-22 13:28:16 +0000
committerDaniel Baumann <daniel.baumann@open-infrastructure.net>2022-11-22 13:45:55 +0000
commit6a4ad68bbe27499c2646d87030d23523a5827498 (patch)
tree74ddc3d78a8c197754d48659c71efa1bd75e40a2
parentReleasing version 20221108. (diff)
downloadservice-tools-6a4ad68bbe27499c2646d87030d23523a5827498.tar.xz
service-tools-6a4ad68bbe27499c2646d87030d23523a5827498.zip
Using certdir variable in dehydrated hook instead of hardcoded path.
Signed-off-by: Daniel Baumann <daniel.baumann@open-infrastructure.net>
-rwxr-xr-xdehydrated/share/hooks/exit_hook.fix-permissions8
1 files changed, 4 insertions, 4 deletions
diff --git a/dehydrated/share/hooks/exit_hook.fix-permissions b/dehydrated/share/hooks/exit_hook.fix-permissions
index 4a467a7..aa15553 100755
--- a/dehydrated/share/hooks/exit_hook.fix-permissions
+++ b/dehydrated/share/hooks/exit_hook.fix-permissions
@@ -21,7 +21,7 @@
set -e
-if [ ! -e /var/lib/dehydrated/certs ]
+if [ ! -e "${CERTDIR}" ]
then
exit 0
fi
@@ -31,10 +31,10 @@ then
echo -n " + Fixing file owner and permissions..."
# https://bugs.debian.org/854431
- chown -R root:ssl-cert /var/lib/dehydrated/certs
+ chown -R root:ssl-cert "${CERTDIR}"
- find /var/lib/dehydrated/certs -type d -exec chmod 0750 {} \;
- find /var/lib/dehydrated/certs -type f -exec chmod 0640 {} \;
+ find "${CERTDIR}" -type d -exec chmod 0750 {} \;
+ find "${CERTDIR}" -type f -exec chmod 0640 {} \;
echo " done."
fi