diff --git a/Dockerfile b/Dockerfile index a274121..668a206 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ # syntax=docker/dockerfile:1 -FROM ghcr.io/linuxserver/baseimage-alpine:3.17 +FROM ghcr.io/linuxserver/baseimage-alpine:3.19 # set version label ARG BUILD_DATE @@ -15,11 +15,12 @@ RUN \ echo "**** install runtime packages ****" && \ apk add --no-cache --upgrade \ nodejs \ - npm \ openssl && \ + apk add --no-cache --upgrade --virtual=build-dependencies \ + npm && \ echo "**** install app ****" && \ mkdir -p \ - /opt/mstream && \ + /app/mstream && \ if [ -z ${MSTREAM_RELEASE+x} ]; then \ MSTREAM_RELEASE=$(curl -sX GET "https://api.github.com/repos/IrosTheBeggar/mStream/releases/latest" \ | awk '/tag_name/{print $4;exit}' FS='[""]'); \ @@ -29,16 +30,19 @@ RUN \ "https://github.com/IrosTheBeggar/mStream/archive/${MSTREAM_RELEASE}.tar.gz" && \ tar xzf \ /tmp/mstream.tar.gz -C \ - /opt/mstream/ --strip-components=1 && \ - cd /opt/mstream && \ + /app/mstream/ --strip-components=1 && \ + cd /app/mstream && \ chown -R abc:abc ./ && \ su -s /bin/sh abc -c 'HOME=/tmp npm install --omit=dev' && \ npm link && \ echo "**** cleanup ****" && \ - rm -rf /opt/mstream/save/sync && \ - ln -s /config/sync /opt/mstream/save/sync && \ + rm -rf /app/mstream/save/sync && \ + ln -s /config/sync /app/mstream/save/sync && \ + apk del --purge \ + build-dependencies && \ rm -rf \ $HOME/.cache \ + $HOME/.npm \ /tmp/* \ /tmp/.npm diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 2c8e23a..22744b5 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -1,6 +1,6 @@ # syntax=docker/dockerfile:1 -FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.17 +FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.19 # set version label ARG BUILD_DATE @@ -15,11 +15,12 @@ RUN \ echo "**** install runtime packages ****" && \ apk add --no-cache --upgrade \ nodejs \ - npm \ openssl && \ + apk add --no-cache --upgrade --virtual=build-dependencies \ + npm && \ echo "**** install app ****" && \ mkdir -p \ - /opt/mstream && \ + /app/mstream && \ if [ -z ${MSTREAM_RELEASE+x} ]; then \ MSTREAM_RELEASE=$(curl -sX GET "https://api.github.com/repos/IrosTheBeggar/mStream/releases/latest" \ | awk '/tag_name/{print $4;exit}' FS='[""]'); \ @@ -29,16 +30,19 @@ RUN \ "https://github.com/IrosTheBeggar/mStream/archive/${MSTREAM_RELEASE}.tar.gz" && \ tar xzf \ /tmp/mstream.tar.gz -C \ - /opt/mstream/ --strip-components=1 && \ - cd /opt/mstream && \ + /app/mstream/ --strip-components=1 && \ + cd /app/mstream && \ chown -R abc:abc ./ && \ su -s /bin/sh abc -c 'HOME=/tmp npm install --omit=dev' && \ npm link && \ echo "**** cleanup ****" && \ - rm -rf /opt/mstream/save/sync && \ - ln -s /config/sync /opt/mstream/save/sync && \ + rm -rf /app/mstream/save/sync && \ + ln -s /config/sync /app/mstream/save/sync && \ + apk del --purge \ + build-dependencies && \ rm -rf \ $HOME/.cache \ + $HOME/.npm \ /tmp/* \ /tmp/.npm diff --git a/README.md b/README.md index 9fa4907..f50839b 100644 --- a/README.md +++ b/README.md @@ -297,6 +297,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **12.12.23:** - Rebase to Alpine 3.19, move binaries to /app. * **05.07.23:** - Deprecate armhf. As announced [here](https://www.linuxserver.io/blog/a-farewell-to-arm-hf) * **13.02.23:** - Rebase to Alpine 3.17, migrate to s6v3. * **05.04.22:** - Move `sync` folder to `/config`. diff --git a/readme-vars.yml b/readme-vars.yml index 8804c69..4aaaccc 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -17,9 +17,6 @@ param_volumes: param_usage_include_ports: true param_ports: - {external_port: "3000", internal_port: "3000", port_desc: "The port for the mStream webinterface"} -param_usage_include_env: true -param_env_vars: - - {env_var: "TZ", env_value: "Europe/London", desc: "Specify a timezone to use e.g. Europe/London"} # application setup block app_setup_block_enabled: true app_setup_block: | @@ -33,6 +30,7 @@ app_setup_block: | v4's `config.json` is not compatible with v5. Existing `config.json` will be renamed to `config.json.v4-bak` for your reference and a new default `config.json` will be created upon upgrade from v4 to v5. # changelog changelogs: + - {date: "12.12.23:", desc: "Rebase to Alpine 3.19, move binaries to /app."} - {date: "05.07.23:", desc: "Deprecate armhf. As announced [here](https://www.linuxserver.io/blog/a-farewell-to-arm-hf)"} - {date: "13.02.23:", desc: "Rebase to Alpine 3.17, migrate to s6v3."} - {date: "05.04.22:", desc: "Move `sync` folder to `/config`."} diff --git a/root/etc/s6-overlay/s6-rc.d/init-mstream-config/run b/root/etc/s6-overlay/s6-rc.d/init-mstream-config/run index 58a04c6..04b07ac 100755 --- a/root/etc/s6-overlay/s6-rc.d/init-mstream-config/run +++ b/root/etc/s6-overlay/s6-rc.d/init-mstream-config/run @@ -41,4 +41,4 @@ fi # permissions lsiown -R abc:abc \ /config \ - /opt/mstream/bin + /app/mstream/bin diff --git a/root/etc/s6-overlay/s6-rc.d/svc-mstream/run b/root/etc/s6-overlay/s6-rc.d/svc-mstream/run index a74fa28..1479f6a 100755 --- a/root/etc/s6-overlay/s6-rc.d/svc-mstream/run +++ b/root/etc/s6-overlay/s6-rc.d/svc-mstream/run @@ -5,4 +5,4 @@ PORT=$(jq -r '.port' /config/config.json) exec \ s6-notifyoncheck -d -n 300 -w 1000 -c "nc -z localhost ${PORT}" \ - cd /opt/mstream s6-setuidgid abc mstream -j /config/config.json + cd /app/mstream s6-setuidgid abc mstream -j /config/config.json