From 406285af63c15b54e8aa1b51dc01763b74fbae3a Mon Sep 17 00:00:00 2001 From: aptalca <541623+aptalca@users.noreply.github.com> Date: Wed, 16 Aug 2023 11:51:28 -0400 Subject: [PATCH] nightly: install unrar from linuxserver repo --- Dockerfile | 17 +++++------------ Dockerfile.aarch64 | 17 +++++------------ README.md | 1 + readme-vars.yml | 1 + 4 files changed, 12 insertions(+), 24 deletions(-) diff --git a/Dockerfile b/Dockerfile index a81ed4e..85b14d9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,9 +1,10 @@ # syntax=docker/dockerfile:1 +FROM ghcr.io/linuxserver/unrar:latest as unrar + FROM ghcr.io/linuxserver/baseimage-alpine:3.18 # set version label -ARG UNRAR_VERSION=6.2.10 ARG BUILD_DATE ARG VERSION ARG SABNZBD_VERSION @@ -28,17 +29,6 @@ RUN \ 7zip \ par2cmdline \ python3 && \ - echo "**** install unrar from source ****" && \ - mkdir /tmp/unrar && \ - curl -o \ - /tmp/unrar.tar.gz -L \ - "https://www.rarlab.com/rar/unrarsrc-${UNRAR_VERSION}.tar.gz" && \ - tar xf \ - /tmp/unrar.tar.gz -C \ - /tmp/unrar --strip-components=1 && \ - cd /tmp/unrar && \ - make && \ - install -v -m755 unrar /usr/local/bin && \ echo "**** install sabnzbd ****" && \ if [ -z ${SABNZBD_VERSION+x} ]; then \ SABNZBD_VERSION=$(curl -s https://api.github.com/repos/sabnzbd/sabnzbd/commits/develop \ @@ -85,6 +75,9 @@ RUN \ # add local files COPY root/ / +# add unrar +COPY --from=unrar /usr/bin/unrar-alpine /usr/bin/unrar + # ports and volumes EXPOSE 8080 VOLUME /config diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index a0127b3..77f402e 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -1,9 +1,10 @@ # syntax=docker/dockerfile:1 +FROM ghcr.io/linuxserver/unrar:arm64v8-latest as unrar + FROM ghcr.io/linuxserver/baseimage-alpine:arm64v8-3.18 # set version label -ARG UNRAR_VERSION=6.2.10 ARG BUILD_DATE ARG VERSION ARG SABNZBD_VERSION @@ -28,17 +29,6 @@ RUN \ 7zip \ par2cmdline \ python3 && \ - echo "**** install unrar from source ****" && \ - mkdir /tmp/unrar && \ - curl -o \ - /tmp/unrar.tar.gz -L \ - "https://www.rarlab.com/rar/unrarsrc-${UNRAR_VERSION}.tar.gz" && \ - tar xf \ - /tmp/unrar.tar.gz -C \ - /tmp/unrar --strip-components=1 && \ - cd /tmp/unrar && \ - make && \ - install -v -m755 unrar /usr/local/bin && \ echo "**** install sabnzbd ****" && \ if [ -z ${SABNZBD_VERSION+x} ]; then \ SABNZBD_VERSION=$(curl -s https://api.github.com/repos/sabnzbd/sabnzbd/commits/develop \ @@ -85,6 +75,9 @@ RUN \ # add local files COPY root/ / +# add unrar +COPY --from=unrar /usr/bin/unrar-alpine /usr/bin/unrar + # ports and volumes EXPOSE 8080 VOLUME /config diff --git a/README.md b/README.md index cc61323..db115c4 100644 --- a/README.md +++ b/README.md @@ -253,6 +253,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **16.08.23:** - Install unrar from [linuxserver repo](https://github.com/linuxserver/docker-unrar). * **10.08.23:** - Bump unrar to 6.2.10. * **03.07.23:** - Deprecate armhf. As announced [here](https://www.linuxserver.io/blog/a-farewell-to-arm-hf) * **11.05.23:** - Rebase nightly branch to Alpine 3.18, deprecate `arm32v7' (armhf) builds. diff --git a/readme-vars.yml b/readme-vars.yml index a65abaa..1fed894 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -47,6 +47,7 @@ app_setup_block_enabled: true app_setup_block: "Initial setup is done via `http://:` ie, http://192.168.1.100:8080.\n\nSee the [SABnzbd wiki](https://sabnzbd.org/wiki/) for more information.\n\n### nzb-notify\n\nnzb-notify is included with this image as a convenience script. To use it set the Scripts folder in the Folder settings to /app/nzbnotify and then configure it under Notifications. See [nzb-notify](https://github.com/caronc/nzb-notify/) for more information.\n\n### Download folders\n\nIn Sabnzbd gui settings, under `Folders`, make sure to set the `Completed Download Folder` as `/downloads` and the `Temporary Download Folder` as `/incomplete-downloads`\n\nWe have set `/incomplete-downloads` and `/downloads` as ***optional paths***, this is because it is the easiest way to get started. While easy to use, it has some drawbacks. Mainly losing the ability to hardlink (TL;DR a way for a file to exist in multiple places on the same file system while only consuming one file worth of space), or atomic move (TL;DR instant file moves, rather than copy+delete) files while processing content.\n\nUse the optional paths if you dont understand, or dont want hardlinks/atomic moves. \n\nThe folks over at servarr.com wrote a good [write-up](https://wiki.servarr.com/docker-guide#consistent-and-well-planned-paths) on how to get started with this.\n" # changelog changelogs: + - {date: "16.08.23:", desc: "Install unrar from [linuxserver repo](https://github.com/linuxserver/docker-unrar)."} - {date: "10.08.23:", desc: "Bump unrar to 6.2.10."} - {date: "03.07.23:", desc: "Deprecate armhf. As announced [here](https://www.linuxserver.io/blog/a-farewell-to-arm-hf)"} - {date: "11.05.23:", desc: "Rebase nightly branch to Alpine 3.18, deprecate `arm32v7' (armhf) builds."}