moved user_patches from misc to nearly the end of setups

This commit is contained in:
Vortex 2019-10-16 18:56:06 +02:00
parent e441f1318a
commit c30c3bf5de

View file

@ -172,7 +172,8 @@ function register_functions() {
if [ "$LOGWATCH_TRIGGER" != "none" ]; then if [ "$LOGWATCH_TRIGGER" != "none" ]; then
_register_setup_function "_setup_logwatch" _register_setup_function "_setup_logwatch"
fi fi
_register_setup_function "_setup_user_patches"
# Compute last as the config files are modified in-place # Compute last as the config files are modified in-place
_register_setup_function "_setup_chksum_file" _register_setup_function "_setup_chksum_file"
@ -195,7 +196,6 @@ function register_functions() {
################### >> misc funcs ################### >> misc funcs
_register_misc_function "_misc_save_states" _register_misc_function "_misc_save_states"
_register_misc_function "_misc_user_patches"
################### << misc funcs ################### << misc funcs
@ -1466,6 +1466,18 @@ function _setup_logwatch() {
esac esac
} }
function _setup_user_patches() {
notify 'inf' 'Executing user-patches.sh'
if [ -f /tmp/docker-mailserver/user-patches.sh ]; then
chmod +x /tmp/docker-mailserver/user-patches.sh
/tmp/docker-mailserver/user-patches.sh
notify 'inf' "Executed 'config/user-patches.sh'"
else
notify 'inf' "No user patches executed because optional '/tmp/docker-mailserver/user-patches.sh' is not provided."
fi
}
function _setup_environment() { function _setup_environment() {
notify 'task' 'Setting up /etc/environment' notify 'task' 'Setting up /etc/environment'
@ -1596,18 +1608,6 @@ function _misc_save_states() {
fi fi
} }
function _misc_user_patches() {
notify 'inf' 'Executing user-patches.sh'
if [ -f /tmp/docker-mailserver/user-patches.sh ]; then
chmod +x /tmp/docker-mailserver/user-patches.sh
/tmp/docker-mailserver/user-patches.sh
notify 'inf' "Executed 'config/user-patches.sh'"
else
notify 'inf' "No user patches executed because optional '/tmp/docker-mailserver/user-patches.sh' is not provided."
fi
}
########################################################################## ##########################################################################
# >> Start Daemons # >> Start Daemons
########################################################################## ##########################################################################