yunohost/data/hooks/conf_regen/35-redis
Quentin Duchemin 6940ea1946
Fix redis hook (bash does not allow empty function
Add a dummy instruction equivalent to true
2020-10-03 11:24:47 +02:00

29 lines
431 B
Bash
Executable file

#!/bin/bash
do_pre_regen() {
:
}
do_post_regen() {
# Enforce these damn permissions because for some reason in some weird cases
# they are spontaneously replaced by root:root -_-
chown -R redis:adm /var/log/redis
}
FORCE=${2:-0}
DRY_RUN=${3:-0}
case "$1" in
pre)
do_pre_regen $4
;;
post)
do_post_regen $4
;;
*)
echo "hook called with unknown argument \`$1'" >&2
exit 1
;;
esac
exit 0