summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO24
-rw-r--r--PKGBUILD35
-rw-r--r--plexpy.install4
-rw-r--r--plexpy.service16
-rw-r--r--welcome.html.patch11
5 files changed, 90 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..c711b1cf54af
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,24 @@
+# Generated by mksrcinfo v8
+# Sun Dec 6 13:11:31 UTC 2015
+pkgbase = plexpy
+ pkgdesc = A Python based monitoring and tracking tool for Plex Media Server.
+ pkgver = 1.2.8
+ pkgrel = 1
+ url = https://github.com/drzoidberg33/plexpy
+ install = plexpy.install
+ arch = any
+ license = GPL
+ depends = python2
+ provides = plexpy
+ conflicts = plexpy-git
+ source = plexpy.tar.gz::https://github.com/drzoidberg33/plexpy/archive/v1.2.8.tar.gz
+ source = plexpy.service
+ source = plexpy.install
+ source = welcome.html.patch
+ sha256sums = 712ca0f53f2be78c336aac0ff1de8ee2f0d6a016d5507c5edaaec8f6b11c82db
+ sha256sums = 007682d19b8573fed06d4f2017080519c6f26793aafba38f01f349627a6b36d5
+ sha256sums = 447c8e08beca653775a7a5d8743c395e058c4c149f864b14a084ff684f6081f8
+ sha256sums = a9c1319185172379ae3bcfd01b4860b4405ffbac3165307c54e084251043ef9f
+
+pkgname = plexpy
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..8e052899dda9
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,35 @@
+# Maintainer: Sonic-Y3k <sonic.y3k@googlemail.com>
+# Based on package by: Denis Saintilma <1068des@gmail.com>
+pkgname=plexpy
+pkgver=1.2.8
+pkgrel=1
+pkgdesc="A Python based monitoring and tracking tool for Plex Media Server."
+arch=('any')
+url="https://github.com/drzoidberg33/plexpy"
+license=('GPL')
+depends=('python2')
+conflicts=('plexpy-git')
+provides=("plexpy")
+install=('plexpy.install')
+source=("$pkgname.tar.gz::https://github.com/drzoidberg33/plexpy/archive/v1.2.8.tar.gz" 'plexpy.service' 'plexpy.install' 'welcome.html.patch')
+sha256sums=('712ca0f53f2be78c336aac0ff1de8ee2f0d6a016d5507c5edaaec8f6b11c82db'
+ '007682d19b8573fed06d4f2017080519c6f26793aafba38f01f349627a6b36d5'
+ '447c8e08beca653775a7a5d8743c395e058c4c149f864b14a084ff684f6081f8'
+ 'a9c1319185172379ae3bcfd01b4860b4405ffbac3165307c54e084251043ef9f')
+
+prepare() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ patch -p0 < "${srcdir}/welcome.html.patch"
+}
+
+package() {
+ cd "${srcdir}/${pkgname}-${pkgver}"
+ install -Dm755 PlexPy.py "${pkgdir}/opt/plexpy/PlexPy.py"
+ install -Dm644 pylintrc "${pkgdir}/opt/plexpy/"
+ install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/plexpy/LICENSE"
+
+ cp -a data/ lib/ plexpy/ "${pkgdir}/opt/plexpy/"
+
+ install -Dm644 "${srcdir}/plexpy.service" "${pkgdir}/usr/lib/systemd/system/plexpy.service"
+}
+
diff --git a/plexpy.install b/plexpy.install
new file mode 100644
index 000000000000..a1f11f0c46fa
--- /dev/null
+++ b/plexpy.install
@@ -0,0 +1,4 @@
+post_install(){
+ getent group plexpy &>/dev/null || groupadd -r plexpy >/dev/null
+ getent passwd plexpy &>/dev/null || useradd -r -g plexpy -s /bin/false plexpy >/dev/null
+}
diff --git a/plexpy.service b/plexpy.service
new file mode 100644
index 000000000000..976e2927a62a
--- /dev/null
+++ b/plexpy.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=PlexPy Service
+
+[Service]
+User=plexpy
+Group=plexpy
+GuessMainPID=no
+Type=forking
+
+PermissionsStartOnly=true
+ExecStartPre=-/usr/bin/mkdir /var/lib/plexpy
+ExecStartPre=/usr/bin/chown -R plexpy:plexpy /var/lib/plexpy/
+ExecStart=/usr/bin/python2 /opt/plexpy/PlexPy.py --quiet --daemon --nolaunch --config /var/lib/plexpy/config.ini --datadir /var/lib/plexpy --nolaunch
+
+[Install]
+WantedBy=default.target
diff --git a/welcome.html.patch b/welcome.html.patch
new file mode 100644
index 000000000000..1eb9f598fc53
--- /dev/null
+++ b/welcome.html.patch
@@ -0,0 +1,11 @@
+--- data/interfaces/default/welcome.html 2015-12-06 13:52:55.157678848 +0100
++++ data/interfaces/default/welcome_new.html 2015-12-06 13:52:26.117956848 +0100
+@@ -169,7 +169,7 @@
+ <input type="checkbox" name="launch_browser" id="launch_browser" value="1" ${config['launch_browser']}>
+ <input type="checkbox" name="refresh_users_on_startup" id="refresh_users_on_startup" value="1" ${config['refresh_users_on_startup']}>
+ <input type="checkbox" name="first_run_complete" id="first_run_complete" value="1" checked>
+- <input type="checkbox" name="check_github" id="check_github" value="1" checked>
++ <input type="checkbox" name="check_github" id="check_github" value="0" checked>
+ </div>
+ </div>
+ <!-- Required fields but hidden -->