mirror of
https://github.com/buanet/ioBroker.docker.git
synced 2025-12-18 10:59:00 +02:00
testing
This commit is contained in:
@@ -51,11 +51,13 @@ COPY scripts/setup_avahi.sh setup_avahi.sh
|
||||
COPY scripts/setup_packages.sh setup_packages.sh
|
||||
COPY scripts/setup_zwave.sh setup_zwave.sh
|
||||
COPY scripts/healthcheck.sh healthcheck.sh
|
||||
COPY scripts/maintenance-mode.sh maintenance-mode.sh
|
||||
RUN chmod +x iobroker_startup.sh \
|
||||
&& chmod +x setup_avahi.sh \
|
||||
&& chmod +x setup_packages.sh \
|
||||
&& chmod +x setup_zwave.sh \
|
||||
&& chmod +x healthcheck.sh
|
||||
&& chmod +x healthcheck.sh \
|
||||
&& chmod +x maintenance-mode.sh
|
||||
WORKDIR /opt/userscripts/
|
||||
COPY scripts/userscript_firststart_example.sh userscript_firststart_example.sh
|
||||
COPY scripts/userscript_everystart_example.sh userscript_everystart_example.sh
|
||||
|
||||
@@ -2,11 +2,11 @@
|
||||
|
||||
if [ "$1" == "status" ]
|
||||
then
|
||||
if [ "$cat /opt/iobroker/.docker_config/.healthcheck" == "maintenance" ]
|
||||
if [ $(cat /opt/iobroker/.docker_config/.healthcheck) == 'maintenance' ]
|
||||
then
|
||||
echo 'Maintenance mode is ON.'
|
||||
exit 0
|
||||
elif [ "$cat /opt/iobroker/.docker_config/.healthcheck" != "maintenance" ]
|
||||
elif [ $(cat /opt/iobroker/.docker_config/.healthcheck) != 'maintenance' ]
|
||||
then
|
||||
echo 'Maintenance mode is OFF.'
|
||||
exit 0
|
||||
@@ -35,7 +35,7 @@ then
|
||||
read -p 'Continue? Type yes or no: ' A
|
||||
if [ "$A" == "y" ] || [ "$A" == "yes" ]
|
||||
then
|
||||
echo "Disabling maintenance mode and forcing container to stop/ restart..."
|
||||
echo 'Disabling maintenance mode and forcing container to stop/ restart...'
|
||||
echo "maintenance" > /opt/iobroker/.docker_config/.healthcheck
|
||||
pkill -u root
|
||||
exit 0
|
||||
|
||||
Reference in New Issue
Block a user