diff --git a/zerotier/Dockerfile b/zerotier/Dockerfile index f75dcdb..49f17d4 100755 --- a/zerotier/Dockerfile +++ b/zerotier/Dockerfile @@ -1,4 +1,4 @@ -ARG BUILD_FROM=ghcr.io/hassio-addons/base/amd64:11.1.2 +ARG BUILD_FROM=ghcr.io/hassio-addons/base/amd64:12.0.0 # hadolint ignore=DL3006 FROM ${BUILD_FROM} @@ -10,15 +10,15 @@ SHELL ["/bin/bash", "-o", "pipefail", "-c"] RUN \ apk add --no-cache --virtual .build-dependencies \ build-base=0.5-r2 \ - cargo=1.56.1-r0 \ - git=2.34.2-r0 \ - linux-headers=5.10.41-r0 \ - openssl-dev=1.1.1n-r0 \ + cargo=1.60.0-r2 \ + git=2.36.1-r0 \ + linux-headers=5.16.7-r1 \ + openssl-dev=1.1.1o-r0 \ pkgconf=1.8.0-r0 \ \ && apk add --no-cache \ - libgcc=10.3.1_git20211027-r0 \ - libstdc++=10.3.1_git20211027-r0 \ + libgcc=11.2.1_git20220219-r2 \ + libstdc++=11.2.1_git20220219-r2 \ \ && git clone --branch "1.8.9" --depth=1 \ "https://github.com/zerotier/ZeroTierOne.git" /tmp/zerotier \ diff --git a/zerotier/build.yaml b/zerotier/build.yaml index b7f18bc..9f7b211 100644 --- a/zerotier/build.yaml +++ b/zerotier/build.yaml @@ -1,10 +1,10 @@ --- build_from: - aarch64: ghcr.io/hassio-addons/base/aarch64:11.1.2 - amd64: ghcr.io/hassio-addons/base/amd64:11.1.2 - armhf: ghcr.io/hassio-addons/base/armhf:11.1.2 - armv7: ghcr.io/hassio-addons/base/armv7:11.1.2 - i386: ghcr.io/hassio-addons/base/i386:11.1.2 + aarch64: ghcr.io/hassio-addons/base/aarch64:12.0.0 + amd64: ghcr.io/hassio-addons/base/amd64:12.0.0 + armhf: ghcr.io/hassio-addons/base/armhf:12.0.0 + armv7: ghcr.io/hassio-addons/base/armv7:12.0.0 + i386: ghcr.io/hassio-addons/base/i386:12.0.0 codenotary: base_image: codenotary@frenck.dev signer: codenotary@frenck.dev diff --git a/zerotier/rootfs/etc/cont-init.d/zerotier.sh b/zerotier/rootfs/etc/cont-init.d/zerotier.sh old mode 100644 new mode 100755 index 91d9266..a005303 --- a/zerotier/rootfs/etc/cont-init.d/zerotier.sh +++ b/zerotier/rootfs/etc/cont-init.d/zerotier.sh @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bashio +#!/command/with-contenv bashio # ============================================================================== # Home Assistant Community Add-on: ZeroTier One # Generates an identiy in case it does not exists yet diff --git a/zerotier/rootfs/etc/services.d/zerotier/finish b/zerotier/rootfs/etc/services.d/zerotier/finish old mode 100644 new mode 100755 index f22964c..dd03827 --- a/zerotier/rootfs/etc/services.d/zerotier/finish +++ b/zerotier/rootfs/etc/services.d/zerotier/finish @@ -1,9 +1,11 @@ -#!/usr/bin/execlineb -S0 +#!/command/with-contenv bashio # ============================================================================== # Home Assistant Community Add-on: ZeroTier One # Take down the S6 supervision tree when ZeroTier fails # ============================================================================== -if -n { s6-test $# -ne 0 } -if -n { s6-test ${1} -eq 256 } +if [[ "${1}" -ne 0 ]] && [[ "${1}" -ne 256 ]]; then + bashio::log.warning "ZeroTier crashed, halting add-on" + /run/s6/basedir/bin/halt +fi -s6-svscanctl -t /var/run/s6/services +bashio::log.info "ZeroTier stopped, restarting..." diff --git a/zerotier/rootfs/etc/services.d/zerotier/run b/zerotier/rootfs/etc/services.d/zerotier/run old mode 100644 new mode 100755 index b336bef..2866cfc --- a/zerotier/rootfs/etc/services.d/zerotier/run +++ b/zerotier/rootfs/etc/services.d/zerotier/run @@ -1,4 +1,4 @@ -#!/usr/bin/with-contenv bashio +#!/command/with-contenv bashio # ============================================================================== # Home Assistant Community Add-on: ZeroTier One # Runs ZeroTier One