First complete

This commit is contained in:
moparisthebest
2016-11-05 02:18:08 -04:00
parent 0887a41178
commit fd2414b131
82 changed files with 1689 additions and 6 deletions

34
src/sonarr/.SRCINFO Normal file
View File

@@ -0,0 +1,34 @@
# Generated by mksrcinfo v8
# Tue Nov 1 19:26:37 UTC 2016
pkgbase = sonarr
pkgdesc = PVR for newsgroup users. Formerly known as NZBDrone
pkgver = 2.0.0.4374
pkgrel = 1
url = https://sonarr.tv
install = sonarr.install
arch = any
license = GPL3
depends = mono
depends = libmediainfo
depends = sqlite
optdepends = sabnzbd: an NZB downloader
optdepends = nzbget: an NZB downloader
optdepends = transmission-cli: a torrent downloader (CLI and daemon version)
optdepends = transmission-gtk: a torrent downloader (GTK+ version)
optdepends = transmission-qt: a torrent downloader (Qt version)
optdepends = deluge: a torrent downloader
provides = nzbdrone
provides = nzbdrone-torrents
conflicts = nzbdrone
conflicts = nzbdrone-torrents
replaces = nzbdrone
replaces = nzbdrone-torrents
source = https://update.sonarr.tv/v2/master/mono/NzbDrone.master.2.0.0.4374.mono.tar.gz
source = sonarr.sh
source = sonarr.service
sha512sums = e18ec5af06f9a0c4fdd3caddcc303367bf963a4669653eec73cad96957b1bd61b35e106d2770da025796ee5c7e25790ead3e9b5b41070ac3dbc632ece2022e8c
sha512sums = 84efa2eebd9afe6b74203aefdc3fdbd4088ecfad17dbe929396f1ffc639743b615a9b75566a0b45d6b7925bd5675368015047c6d65c1421ffe8712728f350695
sha512sums = 438de225c38c26aaa15cae243b18d0be85f3f0e54f1297bf182082a0bdbd936d21928cdcdb899f0f18c6ec32ee88c2e0f0d29b8a2a1cdf98a8e1907cd6f36a2c
pkgname = sonarr

4
src/sonarr/.gitignore vendored Normal file
View File

@@ -0,0 +1,4 @@
NzbDrone.master.*.mono.tar.gz
pkg
sonarr-*.pkg.tar.xz
src

28
src/sonarr/sonarr.install Normal file
View File

@@ -0,0 +1,28 @@
post_install() {
if grep -q "^sonarr" /etc/group &> /dev/null ; then
groupmod -n sonarr sonarr &> /dev/null
else
groupadd -r sonarr &> /dev/null
fi
if grep -q "^sonarr:" /etc/passwd 2> /dev/null ; then
usermod -s /bin/false -c "Sonarr daemon" -d /var/lib/sonarr -g sonarr sonarr &> /dev/null
else
useradd -s /bin/false -c "Sonarr daemon user" -d /var/lib/sonarr -g sonarr -r sonarr &> /dev/null
fi
mkdir -p /var/lib/sonarr
if [[ ! -f /var/lib/sonarr/config.xml ]]
then
if [[ -f /var/lib/nzbdrone/config.xml ]]
then
echo "A previous installation of nzbdrone has been detected. Copying previous configuration to Sonarr"
cp -r /var/lib/nzbdrone/* /var/lib/sonarr
fi
chown -R sonarr: /var/lib/sonarr
fi
}
post_upgrade() {
post_install $1
}

13
src/sonarr/sonarr.service Normal file
View File

@@ -0,0 +1,13 @@
[Unit]
Description=Sonarr Service
After=network.target
[Service]
User=sonarr
Group=sonarr
ExecStart=/usr/bin/sonarr -nobrowser -data=/var/lib/sonarr
Type=simple
TimeoutStopSec=20
[Install]
WantedBy=multi-user.target

2
src/sonarr/sonarr.sh Executable file
View File

@@ -0,0 +1,2 @@
#!/bin/sh
exec mono /usr/lib/sonarr/NzbDrone.exe "$@"