mirror of https://dev.ccchb.de/ccchb/ansible.git
Only delete old service databases after a *successful* update
This commit is contained in:
parent
e8ad17c054
commit
593d8deddf
|
@ -89,10 +89,10 @@ s6_rc_reload()
|
||||||
if s6-rc-update -v 2 -t $update_timeout "/etc/s6-rc/.compiled.$uuid"; then
|
if s6-rc-update -v 2 -t $update_timeout "/etc/s6-rc/.compiled.$uuid"; then
|
||||||
ln -shf ".compiled.$uuid" compiled
|
ln -shf ".compiled.$uuid" compiled
|
||||||
echo "Updated s6-rc service database."
|
echo "Updated s6-rc service database."
|
||||||
fi
|
|
||||||
|
|
||||||
echo "Deleting old service databases."
|
echo "Deleting old service databases."
|
||||||
find -s . -mindepth 1 -maxdepth 1 -type d -name '.compiled.*' -not -name ".compiled.$uuid" -print0 | xargs -0 rm -r
|
find -s . -mindepth 1 -maxdepth 1 -type d -name '.compiled.*' -not -name ".compiled.$uuid" -print0 | xargs -0 rm -r
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
s6_rc_status()
|
s6_rc_status()
|
||||||
|
|
Loading…
Reference in New Issue