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