Browse Source
feat: add alert for update and restart if necessary
The code change adds an alert for updates and restarts the service if necessary. This ensures that the service is restarted after an update to prevent any issues.
pull/4345/head
Daniel Gibbs
2 years ago
No known key found for this signature in database
GPG Key ID: 2076B128385E8C55
1 changed files with
2 additions and
0 deletions
lgsm/modules/check_last_update.sh
@ -20,6 +20,8 @@ if [ -f "${lockdir}/last-updated.lock" ] && [ "${status}" != "0" ]; then
if [ ! -f " ${ lockdir } / ${ selfname } -last-started.lock " ] || [ " ${ laststart } " -lt " ${ lastupdate } " ] ; then
if [ ! -f " ${ lockdir } / ${ selfname } -last-started.lock " ] || [ " ${ laststart } " -lt " ${ lastupdate } " ] ; then
fn_print_info " ${ selfname } has not been restarted since last update "
fn_print_info " ${ selfname } has not been restarted since last update "
fn_script_log_info " ${ selfname } has not been restarted since last update "
fn_script_log_info " ${ selfname } has not been restarted since last update "
alert = "update"
alert.sh
command_restart.sh
command_restart.sh
fn_firstcommand_reset
fn_firstcommand_reset
fi
fi