diff --git a/.travis.yml b/.travis.yml index 885322b..2d8e913 100644 --- a/.travis.yml +++ b/.travis.yml @@ -49,7 +49,7 @@ jobs: - docker run --rm --privileged multiarch/qemu-user-static:register --reset - sed -i "s/\$VERSION/${VERSION}/g" $ARCH/scripts/iobroker_startup.sh - docker build -t "buanet/iobroker:$VERSION-$ARCH" ./armv7hf - + - stage: Manifest env: - JOB_NAME="Manifest" @@ -62,44 +62,44 @@ after_success: if [ "$TRAVIS_BRANCH" == "master" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$JOB_NAME" == "Build images" ] ; then docker push buanet/iobroker:$VERSION-$ARCH fi - + if [ "$TRAVIS_BRANCH" == "beta" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$JOB_NAME" == "Build images" ] ; then docker push buanet/iobroker:$VERSION-$ARCH fi - + # update repository manifest for multiarch and push to hub - > if [ "$TRAVIS_BRANCH" == "master" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$JOB_NAME" == "Manifest" ]; then cat manifest.yml | sed "s/\$VERSION/${VERSION}/g" > manifest.yaml - + #manifest for image: buanet/iobroker:version cat manifest.yaml | sed "s/\$DOCKERTAG/${VERSION}/g" > manifestversion.yaml - + #manifest for image: buanet/iobroker:latest cat manifest.yaml | sed "s/\$DOCKERTAG/latest/g" > manifestlatest.yaml #push to hub mv manifestversion.yaml iobroker.yaml ./manifest-tool --username $HUB_USER --password $HUB_PASS push from-spec iobroker.yaml - + mv manifestlatest.yaml iobroker.yaml ./manifest-tool --username $HUB_USER --password $HUB_PASS push from-spec iobroker.yaml fi - + if [ "$TRAVIS_BRANCH" == "beta" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ] && [ "$JOB_NAME" == "Manifest" ]; then - + cat manifest.yml | sed "s/\$VERSION/${VERSION}/g" > manifest.yaml - + #manifest for image: buanet/iobroker:version cat manifest.yaml | sed "s/\$DOCKERTAG/${VERSION}/g" > manifestversion.yaml - + #manifest for image: buanet/iobroker:beta cat manifest.yaml | sed "s/\$DOCKERTAG/beta/g" > manifestbeta.yaml #push to hub mv manifestversion.yaml iobroker.yaml ./manifest-tool --username $HUB_USER --password $HUB_PASS push from-spec iobroker.yaml - + mv manifestbeta.yaml iobroker.yaml ./manifest-tool --username $HUB_USER --password $HUB_PASS push from-spec iobroker.yaml fi diff --git a/aarch64/Dockerfile b/aarch64/Dockerfile index 8d7e118..0f99a21 100644 --- a/aarch64/Dockerfile +++ b/aarch64/Dockerfile @@ -1,6 +1,6 @@ FROM balenalib/aarch64-debian:stretch -LABEL maintainer="Andre Germann" \ +LABEL maintainer="Andre Germann" \ url="" ENV DEBIAN_FRONTEND noninteractive @@ -84,6 +84,6 @@ ENV ADMINPORT=8081 \ TZ="Europe/Berlin" \ USBDEVICES="none" \ ZWAVE="false" - + # Run startup-script ENTRYPOINT ["/bin/bash", "-c", "/opt/scripts/iobroker_startup.sh"] diff --git a/aarch64/scripts/iobroker_startup.sh b/aarch64/scripts/iobroker_startup.sh index 5653468..a3501de 100644 --- a/aarch64/scripts/iobroker_startup.sh +++ b/aarch64/scripts/iobroker_startup.sh @@ -10,7 +10,7 @@ uid=$SETUID usbdevices=$USBDEVICES zwave=$ZWAVE -# Getting date and time for logging +# Getting date and time for logging dati=`date '+%Y-%m-%d %H:%M:%S'` # Logging header @@ -77,7 +77,7 @@ echo ' ' # Checking and setting uid/gid if [ $(cat /etc/group | grep 'iobroker:' | cut -d':' -f3) != $gid ] || [ $(cat /etc/passwd | grep 'iobroker:' | cut -d':' -f3) != $uid ] -then +then echo "Different UID and/ or GID is set by ENV." echo "Changing UID to "$uid" and GID to "$gid"..." usermod -u $uid iobroker @@ -142,7 +142,7 @@ echo "----- Step 3 of 5: Checking ioBroker installation -----" echo "$(printf -- '-%.0s' {1..60})" echo ' ' -# (Re)Setting permissions to "/opt/iobroker" and "/opt/scripts" +# (Re)Setting permissions to "/opt/iobroker" and "/opt/scripts" echo "(Re)Setting folder permissions (This might take a while! Please be patient!)..." chown -R $uid:$gid /opt/iobroker chown -R $uid:$gid /opt/scripts @@ -222,7 +222,7 @@ fi if [ "$usbdevices" != "none" ] then echo "Usb-device-support is activated by ENV." - + IFS=';' read -ra devicearray <<< "$usbdevices" for i in "${devicearray[@]}" do diff --git a/armv7hf/Dockerfile b/armv7hf/Dockerfile index ad2f366..17f8f79 100644 --- a/armv7hf/Dockerfile +++ b/armv7hf/Dockerfile @@ -1,8 +1,8 @@ FROM balenalib/armv7hf-debian:stretch -LABEL maintainer="Andre Germann" \ +LABEL maintainer="Andre Germann" \ url="" - + ENV DEBIAN_FRONTEND noninteractive # Install prerequisites (as listed in iobroker installer.sh) @@ -84,6 +84,6 @@ ENV ADMINPORT=8081 \ TZ="Europe/Berlin" \ USBDEVICES="none" \ ZWAVE="false" - + # Run startup-script ENTRYPOINT ["/bin/bash", "-c", "/opt/scripts/iobroker_startup.sh"] diff --git a/armv7hf/scripts/iobroker_startup.sh b/armv7hf/scripts/iobroker_startup.sh index 5653468..a3501de 100644 --- a/armv7hf/scripts/iobroker_startup.sh +++ b/armv7hf/scripts/iobroker_startup.sh @@ -10,7 +10,7 @@ uid=$SETUID usbdevices=$USBDEVICES zwave=$ZWAVE -# Getting date and time for logging +# Getting date and time for logging dati=`date '+%Y-%m-%d %H:%M:%S'` # Logging header @@ -77,7 +77,7 @@ echo ' ' # Checking and setting uid/gid if [ $(cat /etc/group | grep 'iobroker:' | cut -d':' -f3) != $gid ] || [ $(cat /etc/passwd | grep 'iobroker:' | cut -d':' -f3) != $uid ] -then +then echo "Different UID and/ or GID is set by ENV." echo "Changing UID to "$uid" and GID to "$gid"..." usermod -u $uid iobroker @@ -142,7 +142,7 @@ echo "----- Step 3 of 5: Checking ioBroker installation -----" echo "$(printf -- '-%.0s' {1..60})" echo ' ' -# (Re)Setting permissions to "/opt/iobroker" and "/opt/scripts" +# (Re)Setting permissions to "/opt/iobroker" and "/opt/scripts" echo "(Re)Setting folder permissions (This might take a while! Please be patient!)..." chown -R $uid:$gid /opt/iobroker chown -R $uid:$gid /opt/scripts @@ -222,7 +222,7 @@ fi if [ "$usbdevices" != "none" ] then echo "Usb-device-support is activated by ENV." - + IFS=';' read -ra devicearray <<< "$usbdevices" for i in "${devicearray[@]}" do diff --git a/manifest.yml b/manifest.yml index ae9fa3b..c8d851a 100644 --- a/manifest.yml +++ b/manifest.yml @@ -16,4 +16,4 @@ manifests: platform: architecture: arm variant: v7 - os: linux \ No newline at end of file + os: linux diff --git a/opt/maintenance-scripts/backup_iobroker_folder.sh b/opt/maintenance-scripts/backup_iobroker_folder.sh index 1f9c2e3..aae1bb0 100644 --- a/opt/maintenance-scripts/backup_iobroker_folder.sh +++ b/opt/maintenance-scripts/backup_iobroker_folder.sh @@ -2,7 +2,7 @@ # Backupscript fuer ein Backup von ioBroker unter Docker auf einer Synology Disk Station (Sicherung des ioBroker-Verzeichnises). # Vorhaltezeit der letzten Backups: 90 Tage, ältere Backups werden automatisch geloescht. -# +# # By Andre Germann # Version 1.1 (22.09.2017) # diff --git a/opt/maintenance-scripts/iobroker_restart.sh b/opt/maintenance-scripts/iobroker_restart.sh index 31d3f60..14d6b92 100644 --- a/opt/maintenance-scripts/iobroker_restart.sh +++ b/opt/maintenance-scripts/iobroker_restart.sh @@ -1,7 +1,7 @@ #!/bin/sh -# Einfaches Script zum Stoppen von ioBroker. -# Kann zum Beispiel aus ioBroker heraus aufgerufen werden um ioBroker neu zu starten. +# Einfaches Script zum Stoppen von ioBroker. +# Kann zum Beispiel aus ioBroker heraus aufgerufen werden um ioBroker neu zu starten. cd /opt/iobroker pkill io diff --git a/opt/maintenance-scripts/iobroker_stop.sh b/opt/maintenance-scripts/iobroker_stop.sh index 4c2e4fc..cab7fb3 100644 --- a/opt/maintenance-scripts/iobroker_stop.sh +++ b/opt/maintenance-scripts/iobroker_stop.sh @@ -1,7 +1,7 @@ #!/bin/sh -# Einfaches Script zum Stoppen von ioBroker. -# Kann zum Beispiel aus ioBroker heraus aufgerufen werden um ioBroker zu stoppen. +# Einfaches Script zum Stoppen von ioBroker. +# Kann zum Beispiel aus ioBroker heraus aufgerufen werden um ioBroker zu stoppen. cd /opt/iobroker pkill io