From 8a5f0ce441f8cf4255b7b11e78934a7c871c8b51 Mon Sep 17 00:00:00 2001 From: mrhotio <26902309+mrhotio@users.noreply.github.com> Date: Tue, 23 Jan 2024 10:45:39 +0100 Subject: [PATCH] change base image --- VERSION.json | 6 +++--- linux-amd64.Dockerfile | 1 - linux-arm64.Dockerfile | 1 - root/etc/s6-overlay/s6-rc.d/init-perms/up | 1 - root/etc/s6-overlay/s6-rc.d/init-secrets/run | 19 ------------------- root/etc/s6-overlay/s6-rc.d/init-secrets/type | 1 - root/etc/s6-overlay/s6-rc.d/init-secrets/up | 1 - .../dependencies.d/init-setup | 0 .../{init-setup => init-setup-app}/run | 16 ---------------- .../{init-perms => init-setup-app}/type | 0 root/etc/s6-overlay/s6-rc.d/init-setup-app/up | 1 + .../init-setup/dependencies.d/init-secrets | 0 root/etc/s6-overlay/s6-rc.d/init-setup/type | 1 - root/etc/s6-overlay/s6-rc.d/init-setup/up | 1 - .../dependencies.d/init-wireguard} | 0 .../s6-rc.d/user/contents.d/init-perms | 0 .../s6-rc.d/user/contents.d/init-secrets | 0 .../s6-rc.d/user/contents.d/init-setup | 0 .../contents.d/init-setup-app} | 0 19 files changed, 4 insertions(+), 45 deletions(-) delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-perms/up delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-secrets/run delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-secrets/type delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-secrets/up rename root/etc/s6-overlay/s6-rc.d/{service-caddy => init-setup-app}/dependencies.d/init-setup (100%) rename root/etc/s6-overlay/s6-rc.d/{init-setup => init-setup-app}/run (77%) rename root/etc/s6-overlay/s6-rc.d/{init-perms => init-setup-app}/type (100%) create mode 100644 root/etc/s6-overlay/s6-rc.d/init-setup-app/up delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-setup/dependencies.d/init-secrets delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-setup/type delete mode 100644 root/etc/s6-overlay/s6-rc.d/init-setup/up rename root/etc/s6-overlay/s6-rc.d/{init-perms/dependencies.d/base => service-caddy/dependencies.d/init-wireguard} (100%) delete mode 100644 root/etc/s6-overlay/s6-rc.d/user/contents.d/init-perms delete mode 100644 root/etc/s6-overlay/s6-rc.d/user/contents.d/init-secrets delete mode 100644 root/etc/s6-overlay/s6-rc.d/user/contents.d/init-setup rename root/etc/s6-overlay/s6-rc.d/{init-secrets/dependencies.d/init-perms => user/contents.d/init-setup-app} (100%) diff --git a/VERSION.json b/VERSION.json index 7dfa2aad..062bfc02 100644 --- a/VERSION.json +++ b/VERSION.json @@ -4,8 +4,8 @@ "version": "2.7.6", "changelog": "https://github.com/caddyserver/caddy/compare/v2.7.5...v2.7.6", "upstream_image": "ghcr.io/hotio/base", - "upstream_tag": "alpine", - "upstream_digest_amd64": "sha256:aba1ad70d73a01a04940ceefcc0506c8867aa99be1e1598f7f57d79dc462ba1d", - "upstream_digest_arm64": "sha256:5f44dcee2c34486af761dca45b1a7b57ef953ee485050544c2255c6f21ed0278", + "upstream_tag": "alpinevpn", + "upstream_digest_amd64": "sha256:e8c549548c101b12abc2fc9399c6c6dc33e5d56603e01f6e3e23fed42d08d54a", + "upstream_digest_arm64": "sha256:b4fca2fdedc503aaa5f73aa1483c442d0ba03113bd359a0ab47ed75a33e5bd9b", "test_url": "http://localhost:8080" } diff --git a/linux-amd64.Dockerfile b/linux-amd64.Dockerfile index 270d7b9f..af43af86 100644 --- a/linux-amd64.Dockerfile +++ b/linux-amd64.Dockerfile @@ -14,7 +14,6 @@ RUN xcaddy_version=$(curl -u "${GITHUB_ACTOR}:${GITHUB_TOKEN}" -fsSL "https://ap FROM ${UPSTREAM_IMAGE}@${UPSTREAM_DIGEST_AMD64} EXPOSE 8080 8443 -VOLUME ["${CONFIG_DIR}"] ENV CUSTOM_BUILD="" COPY --from=builder /caddy-bin "${APP_DIR}/caddy" COPY root/ / diff --git a/linux-arm64.Dockerfile b/linux-arm64.Dockerfile index d64d2f7d..b6ca1d81 100644 --- a/linux-arm64.Dockerfile +++ b/linux-arm64.Dockerfile @@ -14,7 +14,6 @@ RUN xcaddy_version=$(curl -u "${GITHUB_ACTOR}:${GITHUB_TOKEN}" -fsSL "https://ap FROM ${UPSTREAM_IMAGE}@${UPSTREAM_DIGEST_ARM64} EXPOSE 8080 8443 -VOLUME ["${CONFIG_DIR}"] ENV CUSTOM_BUILD="" COPY --from=builder /caddy-bin "${APP_DIR}/caddy" COPY root/ / diff --git a/root/etc/s6-overlay/s6-rc.d/init-perms/up b/root/etc/s6-overlay/s6-rc.d/init-perms/up deleted file mode 100644 index 405161e9..00000000 --- a/root/etc/s6-overlay/s6-rc.d/init-perms/up +++ /dev/null @@ -1 +0,0 @@ -find /etc/s6-overlay/s6-rc.d -name "run*" -execdir chmod +x {} + diff --git a/root/etc/s6-overlay/s6-rc.d/init-secrets/run b/root/etc/s6-overlay/s6-rc.d/init-secrets/run deleted file mode 100644 index e410d339..00000000 --- a/root/etc/s6-overlay/s6-rc.d/init-secrets/run +++ /dev/null @@ -1,19 +0,0 @@ -#!/command/with-contenv bash -# shellcheck shell=bash - -find /var/run/s6/container_environment/ -type f -name 'FILE__*' -print0 | while IFS= read -r -d '' FILENAME; do - NEW_VAR=${FILENAME//FILE__/} - SECRET_FILE=$(cat "${FILENAME}") - if [[ ! -f ${SECRET_FILE} ]]; then - echo "[${NEW_VAR##*/}] The file \"${SECRET_FILE}\" wasn't found!" - exit 1 - fi - SECRET=$(cat "${SECRET_FILE}") - if [[ -n ${SECRET} ]]; then - echo -n "${SECRET}" > "${NEW_VAR}" - echo "[${NEW_VAR##*/}] Set with secret from \"${SECRET_FILE}\"." - else - echo "[${NEW_VAR##*/}] No secret found in \"${SECRET_FILE}\"!" - exit 1 - fi -done diff --git a/root/etc/s6-overlay/s6-rc.d/init-secrets/type b/root/etc/s6-overlay/s6-rc.d/init-secrets/type deleted file mode 100644 index bdd22a18..00000000 --- a/root/etc/s6-overlay/s6-rc.d/init-secrets/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/root/etc/s6-overlay/s6-rc.d/init-secrets/up b/root/etc/s6-overlay/s6-rc.d/init-secrets/up deleted file mode 100644 index 3f032394..00000000 --- a/root/etc/s6-overlay/s6-rc.d/init-secrets/up +++ /dev/null @@ -1 +0,0 @@ -/etc/s6-overlay/s6-rc.d/init-secrets/run diff --git a/root/etc/s6-overlay/s6-rc.d/service-caddy/dependencies.d/init-setup b/root/etc/s6-overlay/s6-rc.d/init-setup-app/dependencies.d/init-setup similarity index 100% rename from root/etc/s6-overlay/s6-rc.d/service-caddy/dependencies.d/init-setup rename to root/etc/s6-overlay/s6-rc.d/init-setup-app/dependencies.d/init-setup diff --git a/root/etc/s6-overlay/s6-rc.d/init-setup/run b/root/etc/s6-overlay/s6-rc.d/init-setup-app/run similarity index 77% rename from root/etc/s6-overlay/s6-rc.d/init-setup/run rename to root/etc/s6-overlay/s6-rc.d/init-setup-app/run index 23e8f6ba..9ad383eb 100644 --- a/root/etc/s6-overlay/s6-rc.d/init-setup/run +++ b/root/etc/s6-overlay/s6-rc.d/init-setup-app/run @@ -7,26 +7,10 @@ echo " ---------------------------------------------------------------------- ENVIRONMENT ---------------------------------------------------------------------- -PUID=${PUID} -PGID=${PGID} -UMASK=${UMASK} -TZ=${TZ} CUSTOM_BUILD=${CUSTOM_BUILD} ---------------------------------------------------------------------- " -echo "Executing usermod..." -mkdir "/tmp/temphome" -usermod -d "/tmp/temphome" hotio -usermod -o -u "${PUID}" hotio -usermod -d "${CONFIG_DIR}" hotio -rm -rf "/tmp/temphome" -groupmod -o -g "${PGID}" hotio - -echo "Applying permissions to ${CONFIG_DIR}" -chmod "=rwx" "${CONFIG_DIR}" -chown hotio:hotio "${CONFIG_DIR}" - if [[ ! -f "${CONFIG_DIR}/Caddyfile" ]]; then echo "Installing default \"Caddyfile\"..." cp "${APP_DIR}/Caddyfile" "${CONFIG_DIR}/Caddyfile" diff --git a/root/etc/s6-overlay/s6-rc.d/init-perms/type b/root/etc/s6-overlay/s6-rc.d/init-setup-app/type similarity index 100% rename from root/etc/s6-overlay/s6-rc.d/init-perms/type rename to root/etc/s6-overlay/s6-rc.d/init-setup-app/type diff --git a/root/etc/s6-overlay/s6-rc.d/init-setup-app/up b/root/etc/s6-overlay/s6-rc.d/init-setup-app/up new file mode 100644 index 00000000..2338a3f9 --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/init-setup-app/up @@ -0,0 +1 @@ +/etc/s6-overlay/s6-rc.d/init-setup-app/run diff --git a/root/etc/s6-overlay/s6-rc.d/init-setup/dependencies.d/init-secrets b/root/etc/s6-overlay/s6-rc.d/init-setup/dependencies.d/init-secrets deleted file mode 100644 index e69de29b..00000000 diff --git a/root/etc/s6-overlay/s6-rc.d/init-setup/type b/root/etc/s6-overlay/s6-rc.d/init-setup/type deleted file mode 100644 index bdd22a18..00000000 --- a/root/etc/s6-overlay/s6-rc.d/init-setup/type +++ /dev/null @@ -1 +0,0 @@ -oneshot diff --git a/root/etc/s6-overlay/s6-rc.d/init-setup/up b/root/etc/s6-overlay/s6-rc.d/init-setup/up deleted file mode 100644 index 33f03323..00000000 --- a/root/etc/s6-overlay/s6-rc.d/init-setup/up +++ /dev/null @@ -1 +0,0 @@ -/etc/s6-overlay/s6-rc.d/init-setup/run diff --git a/root/etc/s6-overlay/s6-rc.d/init-perms/dependencies.d/base b/root/etc/s6-overlay/s6-rc.d/service-caddy/dependencies.d/init-wireguard similarity index 100% rename from root/etc/s6-overlay/s6-rc.d/init-perms/dependencies.d/base rename to root/etc/s6-overlay/s6-rc.d/service-caddy/dependencies.d/init-wireguard diff --git a/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-perms b/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-perms deleted file mode 100644 index e69de29b..00000000 diff --git a/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-secrets b/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-secrets deleted file mode 100644 index e69de29b..00000000 diff --git a/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-setup b/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-setup deleted file mode 100644 index e69de29b..00000000 diff --git a/root/etc/s6-overlay/s6-rc.d/init-secrets/dependencies.d/init-perms b/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-setup-app similarity index 100% rename from root/etc/s6-overlay/s6-rc.d/init-secrets/dependencies.d/init-perms rename to root/etc/s6-overlay/s6-rc.d/user/contents.d/init-setup-app