diff --git a/CHANGELOG.md b/CHANGELOG.md index 3e15359..1e2832a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,9 +1,11 @@ ## Changelog -### v6.1.0-beta.1 (2021-12-23) -* some more corrections in maintenance script ([#232 @agross](https://github.com/buanet/ioBroker.docker/pull/232)) -* added autoconfirm parameter to upgrade function in maintenance script ([#229 @thost96](https://github.com/buanet/ioBroker.docker/pull/229)) -* added alias "m" for maintenance script +### v6.1.0-beta.2 (upcoming) +* adding breaks and optimizing maintenance script (fixes [#233](https://github.com/buanet/ioBroker.docker/issues/233)) +* v6.1.0-beta.1 (2021-12-23) + * some more corrections in maintenance script ([#232 @agross](https://github.com/buanet/ioBroker.docker/pull/232)) + * added autoconfirm parameter to upgrade function in maintenance script ([#229 @thost96](https://github.com/buanet/ioBroker.docker/pull/229)) + * added alias "m" for maintenance script ### v6.0.0 (2021-12-09) * moving docu/ restructuring readme diff --git a/debian/scripts/maintenance.sh b/debian/scripts/maintenance.sh index 11aa914..10f38c9 100644 --- a/debian/scripts/maintenance.sh +++ b/debian/scripts/maintenance.sh @@ -148,17 +148,20 @@ upgrade() { then echo 'This command was already confirmed by -y or --yes option.' fi - - echo 'Activating maintenance mode...' - echo "maintenance" > /opt/scripts/.docker_config/.healthcheck - sleep 1 - echo 'Done.' - echo 'Stopping ioBroker...' - pkill -u iobroker - sleep 1 - echo 'Done.' + if [ $(cat /opt/scripts/.docker_config/.healthcheck) != 'maintenance' ] + then + echo 'Activating maintenance mode...' + echo "maintenance" > /opt/scripts/.docker_config/.healthcheck + sleep 1 + echo 'Done.' + echo 'Stopping ioBroker...' + pkill -u iobroker + sleep 5 + echo 'Done.' + fi echo 'Upgrading js-controller...' iobroker update + sleep 1 iobroker upgrade self sleep 1 echo 'Done.'