diff --git a/Dockerfile b/Dockerfile index a92251d..08d77c6 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,27 +1,31 @@ -FROM lsiobase/alpine.python +FROM lsiobase/xenial MAINTAINER sparklyballs -# install sabnzbd +# environment settings +ENV HOME="/config" +ARG DEBIAN_FRONTEND="noninteractive" + +# install packages RUN \ - mkdir -p \ - /app/sabnzbd && \ - LATEST_RELEASE=$(curl -sX GET "https://api.github.com/repos/sabnzbd/sabnzbd/releases/latest" | \ - awk '/tag_name/{print $4;exit}' FS='[""]') && \ - curl -o \ - /tmp/sabnzbd.tar.gz -L \ - https://github.com/sabnzbd/sabnzbd/releases/download/"${LATEST_RELEASE}"/SABnzbd-"${LATEST_RELEASE}"-src.tar.gz && \ - tar xf \ - /tmp/sabnzbd.tar.gz -C \ - /app/sabnzbd --strip-components=1 && \ + echo "deb http://ppa.launchpad.net/jcfp/ppa/ubuntu xenial main" | tee -a /etc/apt/sources.list && \ + apt-key adv --keyserver hkp://keyserver.ubuntu.com:11371 --recv-keys 0x98703123E0F52B2BE16D586EF13930B14BB9F05F && \ + apt-get update && \ + apt-get install -y \ + p7zip-full \ + sabnzbdplus \ + unrar \ + unzip && \ -# cleanup - rm -f \ - /tmp/* +# cleanup + apt-get clean && \ + rm -rf \ + /tmp/* \ + /var/lib/apt/lists/* \ + /var/tmp/* -# add local files +# add local files COPY root/ / # ports and volumes -VOLUME /config /downloads /incomplete-downloads EXPOSE 8080 9090 - +VOLUME /config /downloads /incomplete-downloads diff --git a/README.md b/README.md index bcf74e7..f670d25 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ The [LinuxServer.io](https://linuxserver.io) team brings you another container r * [Podcast](https://www.linuxserver.io/index.php/category/podcast/) covers everything to do with getting the most from your Linux Server plus a focus on all things Docker and containerisation! # linuxserver/sabnzbd -[![Docker Pulls](https://img.shields.io/docker/pulls/linuxserver/sabnzbd.svg)][hub][![Docker Stars](https://img.shields.io/docker/stars/linuxserver/sabnzbd.svg)][hub][![Build Status](http://jenkins.linuxserver.io:8080/buildStatus/icon?job=Dockers/LinuxServer.io/linuxserver-sabnzbd)](http://jenkins.linuxserver.io:8080/job/Dockers/job/LinuxServer.io/job/linuxserver-sabnzbd/) +[![](https://images.microbadger.com/badges/image/linuxserver/sabnzbd.svg)](http://microbadger.com/images/linuxserver/sabnzbd "Get your own image badge on microbadger.com")[![Docker Pulls](https://img.shields.io/docker/pulls/linuxserver/sabnzbd.svg)][hub][![Docker Stars](https://img.shields.io/docker/stars/linuxserver/sabnzbd.svg)][hub][![Build Status](http://jenkins.linuxserver.io:8080/buildStatus/icon?job=Dockers/LinuxServer.io/linuxserver-sabnzbd)](http://jenkins.linuxserver.io:8080/job/Dockers/job/LinuxServer.io/job/linuxserver-sabnzbd/) [hub]: https://hub.docker.com/r/linuxserver/sabnzbd/ SABnzbd makes Usenet as simple and streamlined as possible by automating everything we can. All you have to do is add an .nzb. SABnzbd takes over from there, where it will be automatically downloaded, verified, repaired, extracted and filed away with zero human interaction. @@ -39,6 +39,8 @@ linuxserver/sabnzbd * `-e PUID` for UserID - see below for explanation * `-e TZ` for setting timezone information, eg Europe/London +It is based on ubuntu xenial with s6 overlay, for shell access whilst the container is running do `docker exec -it sabnzbd /bin/bash`. + ### User / Group Identifiers Sometimes when using data volumes (`-v` flags) permissions issues can arise between the host OS and the container. We avoid this issue by allowing you to specify the user `PUID` and group `PGID`. Ensure the data volume directory on the host is owned by the same user you specify and it will "just work" ™. @@ -64,6 +66,8 @@ See here for info on some of the switch settings for sabnzbd http://wiki.sabnzbd ## Versions ++ **09.09.16:** Rebase back to xenial, +issues with alpine version of python and 1.10 branch of sab. + **28.08.16:** Rebase to alpine, using git version of sab. + **17.03.16:** Bump to install 1.0 final at startup + **14.03.16:** Refresh image to pick up latest RC diff --git a/root/etc/cont-init.d/20-config b/root/etc/cont-init.d/20-config index 1d6987f..9de439b 100644 --- a/root/etc/cont-init.d/20-config +++ b/root/etc/cont-init.d/20-config @@ -1,13 +1,12 @@ #!/usr/bin/with-contenv bash -# make folders +# make folders mkdir -p \ /downloads \ /incomplete-downloads -# permissions -chown -R abc:abc \ - /app/sabnzbd +# permissions chown abc:abc \ /downloads \ /incomplete-downloads + diff --git a/root/etc/services.d/sabnzbd/run b/root/etc/services.d/sabnzbd/run index a421b75..1a88e63 100644 --- a/root/etc/services.d/sabnzbd/run +++ b/root/etc/services.d/sabnzbd/run @@ -1,5 +1,7 @@ #!/usr/bin/with-contenv bash exec \ - s6-setuidgid abc python /app/sabnzbd/SABnzbd.py \ - -f /config/sabnzbd.ini -b 0 -s 0.0.0.0:8080 + s6-setuidgid abc /usr/bin/sabnzbdplus \ + --config-file /config --server 0.0.0.0:8080 + +