diff --git a/Dockerfile b/Dockerfile index c16e540..38e6e0c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ghcr.io/linuxserver/baseimage-alpine:3.13 +FROM ghcr.io/linuxserver/baseimage-alpine:3.16 # set version label ARG BUILD_DATE @@ -8,33 +8,33 @@ LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DA LABEL maintainer="sparklyballs" RUN \ - echo "**** install build packages ****" && \ - apk add --no-cache --virtual=build-dependencies \ - curl \ - unzip && \ - echo "**** install runtime packages ****" && \ - apk add --no-cache \ - openjdk8-jre-base && \ - echo "**** install ubooquity ****" && \ - if [ -z ${UBOOQUITY_VERSION+x} ]; then \ - UBOOQUITY_VERSION=$(curl -IsL -w %{url_effective} -o /dev/null http://vaemendis.net/ubooquity/service/download.php \ - | sed 's|.*Ubooquity-\([0-9\.]*\).zip|\1|'); \ - fi && \ - mkdir -p \ - /app/ubooquity && \ - curl -o \ - /tmp/ubooquity.zip -L \ - "http://vaemendis.net/ubooquity/downloads/Ubooquity-${UBOOQUITY_VERSION}.zip" && \ - unzip /tmp/ubooquity.zip -d /app/ubooquity && \ - echo "**** cleanup ****" && \ - apk del --purge \ - build-dependencies && \ - rm -rf \ - /tmp/* + echo "**** install build packages ****" && \ + apk add --no-cache --virtual=build-dependencies \ + unzip && \ + echo "**** install runtime packages ****" && \ + apk add --no-cache \ + openjdk8-jre-base && \ + echo "**** install ubooquity ****" && \ + if [ -z ${UBOOQUITY_VERSION+x} ]; then \ + UBOOQUITY_VERSION=$(curl -IsL -w %{url_effective} -o /dev/null http://vaemendis.net/ubooquity/service/download.php \ + | sed 's|.*Ubooquity-\([0-9\.]*\).zip|\1|'); \ + fi && \ + mkdir -p \ + /app/ubooquity && \ + curl -o \ + /tmp/ubooquity.zip -L \ + "http://vaemendis.net/ubooquity/downloads/Ubooquity-${UBOOQUITY_VERSION}.zip" && \ + unzip /tmp/ubooquity.zip -d /app/ubooquity && \ + echo "**** cleanup ****" && \ + apk del --purge \ + build-dependencies && \ + rm -rf \ + /tmp/* # copy local files COPY root/ / # ports and volumes EXPOSE 2202 2203 -VOLUME /books /comics /config /files + +VOLUME /config diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 196a8cd..69daf5e 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -1,4 +1,4 @@ -FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.13 +FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.16 # set version label ARG BUILD_DATE @@ -8,33 +8,33 @@ LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DA LABEL maintainer="sparklyballs" RUN \ - echo "**** install build packages ****" && \ - apk add --no-cache --virtual=build-dependencies \ - curl \ - unzip && \ - echo "**** install runtime packages ****" && \ - apk add --no-cache \ - openjdk8-jre-base && \ - echo "**** install ubooquity ****" && \ - if [ -z ${UBOOQUITY_VERSION+x} ]; then \ - UBOOQUITY_VERSION=$(curl -IsL -w %{url_effective} -o /dev/null http://vaemendis.net/ubooquity/service/download.php \ - | sed 's|.*Ubooquity-\([0-9\.]*\).zip|\1|'); \ - fi && \ - mkdir -p \ - /app/ubooquity && \ - curl -o \ - /tmp/ubooquity.zip -L \ - "http://vaemendis.net/ubooquity/downloads/Ubooquity-${UBOOQUITY_VERSION}.zip" && \ - unzip /tmp/ubooquity.zip -d /app/ubooquity && \ - echo "**** cleanup ****" && \ - apk del --purge \ - build-dependencies && \ - rm -rf \ - /tmp/* + echo "**** install build packages ****" && \ + apk add --no-cache --virtual=build-dependencies \ + unzip && \ + echo "**** install runtime packages ****" && \ + apk add --no-cache \ + openjdk8-jre-base && \ + echo "**** install ubooquity ****" && \ + if [ -z ${UBOOQUITY_VERSION+x} ]; then \ + UBOOQUITY_VERSION=$(curl -IsL -w %{url_effective} -o /dev/null http://vaemendis.net/ubooquity/service/download.php \ + | sed 's|.*Ubooquity-\([0-9\.]*\).zip|\1|'); \ + fi && \ + mkdir -p \ + /app/ubooquity && \ + curl -o \ + /tmp/ubooquity.zip -L \ + "http://vaemendis.net/ubooquity/downloads/Ubooquity-${UBOOQUITY_VERSION}.zip" && \ + unzip /tmp/ubooquity.zip -d /app/ubooquity && \ + echo "**** cleanup ****" && \ + apk del --purge \ + build-dependencies && \ + rm -rf \ + /tmp/* # copy local files COPY root/ / # ports and volumes EXPOSE 2202 2203 -VOLUME /books /comics /config /files + +VOLUME /config diff --git a/Dockerfile.armhf b/Dockerfile.armhf index 18509a9..5ac6251 100644 --- a/Dockerfile.armhf +++ b/Dockerfile.armhf @@ -1,4 +1,4 @@ -FROM ghcr.io/linuxserver/baseimage-alpine:arm32v7-3.13 +FROM ghcr.io/linuxserver/baseimage-alpine:arm32v7-3.16 # set version label ARG BUILD_DATE @@ -8,33 +8,33 @@ LABEL build_version="Linuxserver.io version:- ${VERSION} Build-date:- ${BUILD_DA LABEL maintainer="sparklyballs" RUN \ - echo "**** install build packages ****" && \ - apk add --no-cache --virtual=build-dependencies \ - curl \ - unzip && \ - echo "**** install runtime packages ****" && \ - apk add --no-cache \ - openjdk8-jre-base && \ - echo "**** install ubooquity ****" && \ - if [ -z ${UBOOQUITY_VERSION+x} ]; then \ - UBOOQUITY_VERSION=$(curl -IsL -w %{url_effective} -o /dev/null http://vaemendis.net/ubooquity/service/download.php \ - | sed 's|.*Ubooquity-\([0-9\.]*\).zip|\1|'); \ - fi && \ - mkdir -p \ - /app/ubooquity && \ - curl -o \ - /tmp/ubooquity.zip -L \ - "http://vaemendis.net/ubooquity/downloads/Ubooquity-${UBOOQUITY_VERSION}.zip" && \ - unzip /tmp/ubooquity.zip -d /app/ubooquity && \ - echo "**** cleanup ****" && \ - apk del --purge \ - build-dependencies && \ - rm -rf \ - /tmp/* + echo "**** install build packages ****" && \ + apk add --no-cache --virtual=build-dependencies \ + unzip && \ + echo "**** install runtime packages ****" && \ + apk add --no-cache \ + openjdk8-jre-base && \ + echo "**** install ubooquity ****" && \ + if [ -z ${UBOOQUITY_VERSION+x} ]; then \ + UBOOQUITY_VERSION=$(curl -IsL -w %{url_effective} -o /dev/null http://vaemendis.net/ubooquity/service/download.php \ + | sed 's|.*Ubooquity-\([0-9\.]*\).zip|\1|'); \ + fi && \ + mkdir -p \ + /app/ubooquity && \ + curl -o \ + /tmp/ubooquity.zip -L \ + "http://vaemendis.net/ubooquity/downloads/Ubooquity-${UBOOQUITY_VERSION}.zip" && \ + unzip /tmp/ubooquity.zip -d /app/ubooquity && \ + echo "**** cleanup ****" && \ + apk del --purge \ + build-dependencies && \ + rm -rf \ + /tmp/* # copy local files COPY root/ / # ports and volumes EXPOSE 2202 2203 -VOLUME /books /comics /config /files + +VOLUME /config diff --git a/README.md b/README.md index f715589..280feef 100644 --- a/README.md +++ b/README.md @@ -251,6 +251,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **10.10.22:** - Rebasing to alpine 3.16, migrate to s6v3. * **23.01.21:** - Rebasing to alpine 3.13. * **01.06.20:** - Rebasing to alpine 3.12. * **19.12.19:** - Rebasing to alpine 3.11. diff --git a/readme-vars.yml b/readme-vars.yml index 40b0e3d..c6f458c 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -68,6 +68,7 @@ app_setup_block: | # changelog changelogs: + - { date: "10.10.22:", desc: "Rebasing to alpine 3.16, migrate to s6v3." } - { date: "23.01.21:", desc: "Rebasing to alpine 3.13." } - { date: "01.06.20:", desc: "Rebasing to alpine 3.12." } - { date: "19.12.19:", desc: "Rebasing to alpine 3.11." } diff --git a/root/etc/cont-init.d/30-config b/root/etc/cont-init.d/30-config deleted file mode 100644 index b40a5a6..0000000 --- a/root/etc/cont-init.d/30-config +++ /dev/null @@ -1,14 +0,0 @@ -#!/usr/bin/with-contenv bash - -# make our folders -mkdir -p \ - config/fonts - -# copy config -[[ ! -e /config/preferences.json ]] && \ - cp /defaults/preferences.json /config/preferences.json - -# permissions -chown -R abc:abc \ - /config \ - /app/ubooquity diff --git a/root/etc/s6-overlay/s6-rc.d/init-config-end/dependencies.d/init-ubooquity-config b/root/etc/s6-overlay/s6-rc.d/init-config-end/dependencies.d/init-ubooquity-config new file mode 100644 index 0000000..e69de29 diff --git a/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/dependencies.d/init-config b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/dependencies.d/init-config new file mode 100644 index 0000000..e69de29 diff --git a/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/run b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/run new file mode 100755 index 0000000..9489de0 --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/run @@ -0,0 +1,15 @@ +#!/usr/bin/with-contenv bash + +# make our folders +mkdir -p \ + config/fonts + +# copy config +if [[ ! -f /config/preferences.json ]]; then + cp /defaults/preferences.json /config/preferences.json +fi + +# permissions +chown -R abc:abc \ + /config \ + /app/ubooquity diff --git a/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/type b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/type new file mode 100644 index 0000000..3d92b15 --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/type @@ -0,0 +1 @@ +oneshot \ No newline at end of file diff --git a/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/up b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/up new file mode 100644 index 0000000..a618ca3 --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/init-ubooquity-config/up @@ -0,0 +1 @@ +/etc/s6-overlay/s6-rc.d/init-ubooquity-config/run \ No newline at end of file diff --git a/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/dependencies.d/init-services b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/dependencies.d/init-services new file mode 100644 index 0000000..e69de29 diff --git a/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/notification-fd b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/notification-fd new file mode 100644 index 0000000..00750ed --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/notification-fd @@ -0,0 +1 @@ +3 diff --git a/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/run b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/run new file mode 100755 index 0000000..caaa581 --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/run @@ -0,0 +1,10 @@ +#!/usr/bin/with-contenv bash + +JAVAMEM=${MAXMEM:-512} + +exec \ + s6-notifyoncheck -d -n 300 -w 1000 -c "nc -z localhost 2203" \ + cd /app/ubooquity s6-setuidgid abc java -Xmx"$JAVAMEM"m \ + -jar /app/ubooquity/Ubooquity.jar \ + --headless --host 0.0.0.0 --remoteadmin \ + --workdir /config diff --git a/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/type b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/type new file mode 100644 index 0000000..1780f9f --- /dev/null +++ b/root/etc/s6-overlay/s6-rc.d/svc-ubooquity/type @@ -0,0 +1 @@ +longrun \ No newline at end of file diff --git a/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-ubooquity-config b/root/etc/s6-overlay/s6-rc.d/user/contents.d/init-ubooquity-config new file mode 100644 index 0000000..e69de29 diff --git a/root/etc/s6-overlay/s6-rc.d/user/contents.d/svc-ubooquity b/root/etc/s6-overlay/s6-rc.d/user/contents.d/svc-ubooquity new file mode 100644 index 0000000..e69de29 diff --git a/root/etc/services.d/ubooquity/run b/root/etc/services.d/ubooquity/run deleted file mode 100644 index b5fe1f0..0000000 --- a/root/etc/services.d/ubooquity/run +++ /dev/null @@ -1,11 +0,0 @@ -#!/usr/bin/with-contenv bash - -JAVAMEM=${MAXMEM:-512} - -cd /app/ubooquity || exit - -exec \ - s6-setuidgid abc java -Xmx"$JAVAMEM"m \ - -jar /app/ubooquity/Ubooquity.jar \ - --headless --host 0.0.0.0 --remoteadmin \ - --workdir /config