From 3182b7be876ec7640e6e4ddccbb4b653554f754b Mon Sep 17 00:00:00 2001 From: TheSpad Date: Wed, 13 Sep 2023 13:33:02 +0100 Subject: [PATCH] Switch to par2cmdline-turbo --- Dockerfile | 25 +++++++++++++++++++++---- Dockerfile.aarch64 | 25 +++++++++++++++++++++---- README.md | 3 ++- readme-vars.yml | 7 ++++--- 4 files changed, 48 insertions(+), 12 deletions(-) diff --git a/Dockerfile b/Dockerfile index b0d8876..68dbb4b 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,15 +18,16 @@ ENV HOME="/config" \ RUN \ echo "**** install packages ****" && \ apk add -U --update --no-cache --virtual=build-dependencies \ + autoconf \ + automake \ build-base \ libffi-dev \ openssl-dev \ python3-dev && \ apk add -U --update --no-cache \ 7zip \ - par2cmdline \ python3 && \ - echo "**** install sabnzbd ****" && \ + echo "**** install sabnzbd ****" && \ if [ -z ${SABNZBD_VERSION+x} ]; then \ SABNZBD_VERSION=$(curl -s https://api.github.com/repos/sabnzbd/sabnzbd/releases \ | jq -r 'first(.[]) | .tag_name'); \ @@ -48,7 +49,23 @@ RUN \ pynzb \ requests && \ pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ -r requirements.txt && \ - echo "**** install nzb-notify ****" && \ + echo "**** install par2cmdline-turbo from source ****" && \ + PAR2_VERSION=$(curl -s https://api.github.com/repos/animetosho/par2cmdline-turbo/releases/latest \ + | awk '/tag_name/{print $4;exit}' FS='[""]'); \ + mkdir /tmp/par2cmdline && \ + curl -o \ + /tmp/par2cmdline.tar.gz -L \ + "https://github.com/animetosho/par2cmdline-turbo/archive/${PAR2_VERSION}.tar.gz" && \ + tar xf \ + /tmp/par2cmdline.tar.gz -C \ + /tmp/par2cmdline --strip-components=1 && \ + cd /tmp/par2cmdline && \ + ./automake.sh && \ + ./configure && \ + make && \ + make check && \ + make install && \ + echo "**** install nzb-notify ****" && \ NZBNOTIFY_VERSION=$(curl -s https://api.github.com/repos/caronc/nzb-notify/releases/latest \ | awk '/tag_name/{print $4;exit}' FS='[""]') && \ mkdir -p /app/nzbnotify && \ @@ -59,7 +76,7 @@ RUN \ /tmp/nzbnotify.tar.gz -C \ /app/nzbnotify --strip-components=1 && \ cd /app/nzbnotify && \ - pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ -r requirements.txt && \ + pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ -r requirements.txt && \ echo "**** cleanup ****" && \ apk del --purge \ build-dependencies && \ diff --git a/Dockerfile.aarch64 b/Dockerfile.aarch64 index 665806d..c22c835 100644 --- a/Dockerfile.aarch64 +++ b/Dockerfile.aarch64 @@ -18,15 +18,16 @@ ENV HOME="/config" \ RUN \ echo "**** install packages ****" && \ apk add -U --update --no-cache --virtual=build-dependencies \ + autoconf \ + automake \ build-base \ libffi-dev \ openssl-dev \ python3-dev && \ apk add -U --update --no-cache \ 7zip \ - par2cmdline \ python3 && \ - echo "**** install sabnzbd ****" && \ + echo "**** install sabnzbd ****" && \ if [ -z ${SABNZBD_VERSION+x} ]; then \ SABNZBD_VERSION=$(curl -s https://api.github.com/repos/sabnzbd/sabnzbd/releases \ | jq -r 'first(.[]) | .tag_name'); \ @@ -48,7 +49,23 @@ RUN \ pynzb \ requests && \ pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ -r requirements.txt && \ - echo "**** install nzb-notify ****" && \ + echo "**** install par2cmdline-turbo from source ****" && \ + PAR2_VERSION=$(curl -s https://api.github.com/repos/animetosho/par2cmdline-turbo/releases/latest \ + | awk '/tag_name/{print $4;exit}' FS='[""]'); \ + mkdir /tmp/par2cmdline && \ + curl -o \ + /tmp/par2cmdline.tar.gz -L \ + "https://github.com/animetosho/par2cmdline-turbo/archive/${PAR2_VERSION}.tar.gz" && \ + tar xf \ + /tmp/par2cmdline.tar.gz -C \ + /tmp/par2cmdline --strip-components=1 && \ + cd /tmp/par2cmdline && \ + ./automake.sh && \ + ./configure && \ + make && \ + make check && \ + make install && \ + echo "**** install nzb-notify ****" && \ NZBNOTIFY_VERSION=$(curl -s https://api.github.com/repos/caronc/nzb-notify/releases/latest \ | awk '/tag_name/{print $4;exit}' FS='[""]') && \ mkdir -p /app/nzbnotify && \ @@ -59,7 +76,7 @@ RUN \ /tmp/nzbnotify.tar.gz -C \ /app/nzbnotify --strip-components=1 && \ cd /app/nzbnotify && \ - pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ -r requirements.txt && \ + pip install -U --no-cache-dir --find-links https://wheel-index.linuxserver.io/alpine-3.18/ -r requirements.txt && \ echo "**** cleanup ****" && \ apk del --purge \ build-dependencies && \ diff --git a/README.md b/README.md index eb9fbfb..192816a 100644 --- a/README.md +++ b/README.md @@ -83,7 +83,7 @@ In Sabnzbd gui settings, under `Folders`, make sure to set the `Completed Downlo We 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. -Use the optional paths if you dont understand, or dont want hardlinks/atomic moves. +Use the optional paths if you dont understand, or dont want hardlinks/atomic moves. The 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. @@ -253,6 +253,7 @@ Once registered you can define the dockerfile to use with `-f Dockerfile.aarch64 ## Versions +* **13.09.23:** - Use par2cmdline-turbo in place of par2cmdline. * **16.08.23:** - Install unrar from [linuxserver repo](https://github.com/linuxserver/docker-unrar). * **10.08.23:** - Bump unrar to 6.2.10. * **16.05.23:** - Rebase unstable to Alpine 3.18, deprecate armhf. diff --git a/readme-vars.yml b/readme-vars.yml index 1a6f9d4..46a2d30 100644 --- a/readme-vars.yml +++ b/readme-vars.yml @@ -53,9 +53,9 @@ app_setup_block: | Initial setup is done via `http://:` ie, http://192.168.1.100:8080. See the [SABnzbd wiki](https://sabnzbd.org/wiki/) for more information. - + ### nzb-notify - + nzb-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. ### Download folders @@ -64,12 +64,13 @@ app_setup_block: | We 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. - Use the optional paths if you dont understand, or dont want hardlinks/atomic moves. + Use the optional paths if you dont understand, or dont want hardlinks/atomic moves. The 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. # changelog changelogs: + - {date: "13.09.23:", desc: "Use par2cmdline-turbo in place of par2cmdline."} - { 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: "16.05.23:", desc: "Rebase unstable to Alpine 3.18, deprecate armhf." }