summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO28
-rw-r--r--.gitignore3
-rw-r--r--PKGBUILD26
-rw-r--r--pyca-agentstate.service8
-rw-r--r--pyca-capture.service8
-rw-r--r--pyca-ingest.service8
-rw-r--r--pyca-schedule.service8
-rw-r--r--pyca-ui.service6
-rw-r--r--pyca.service17
9 files changed, 64 insertions, 48 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 55c18204cf95..54c11b99d9f2 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,20 +1,21 @@
pkgbase = pyca
pkgdesc = Python Capture Agent for Opencast
- pkgver = 2.1
- pkgrel = 5
+ pkgver = 3.2
+ pkgrel = 6
url = https://github.com/opencast/pyCA
install = pyca.install
arch = any
license = LGPL
- depends = gnutls
+ depends = python-pycurl
depends = python-dateutil
depends = python-configobj
- depends = python-flask
- depends = python-pycurl
depends = python-sqlalchemy
+ depends = python-sdnotify
+ depends = python-psutil
+ depends = python-flask
optdepends = gunicorn: wsgi web interface
backup = etc/pyca.conf
- source = https://github.com/opencast/pyCA/archive/v2.1.tar.gz
+ source = https://github.com/opencast/pyCA/archive/v3.2.tar.gz
source = pyca.install
source = pyca.service
source = pyca-ui.service
@@ -22,14 +23,13 @@ pkgbase = pyca
source = pyca-capture.service
source = pyca-ingest.service
source = pyca-schedule.service
- md5sums = c48f246eff3e33a04310da39c01578bf
+ md5sums = 9db4a8d30754458a624c23af1b1a7572
md5sums = d16c4e1a394f0cf356f65555e8cb0334
- md5sums = c014533da3c3b9bb763419e2721e844a
- md5sums = 965c239a4c7a2d528f1ce559f8224ac7
- md5sums = 3d64e43407482b906b5e21f2a5584a6e
- md5sums = 2eb31065c6d4deb6888c3b187565add9
- md5sums = 4adcf6d8ff3641ad1dd4910a1957c9db
- md5sums = e86a4025da5842d701a12cc258116c66
+ md5sums = ad2dff096f5fd249f30137088ea5130d
+ md5sums = e00ff2fb7ded9f6ef2c01b6dccb8bb7c
+ md5sums = 00d4bc93ddd9de5226cbfad53e1b4d10
+ md5sums = eac3ed5d9f9766bcc4b455b69056b351
+ md5sums = e0ee6375752f98e3dfca8c9a5b2b776f
+ md5sums = f17d472d7de8f63e6b563fd38ac81314
pkgname = pyca
-
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..0918f8b7ee87
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,3 @@
+pkg/*
+src/*
+*tar*
diff --git a/PKGBUILD b/PKGBUILD
index b1d2f93ec52c..d176dbb9f66b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,13 +1,13 @@
#Maintainer: Jan Koppe <post@jankoppe.de>
pkgname=pyca
-pkgver=2.1
-pkgrel=5
+pkgver=3.2
+pkgrel=6
pkgdesc="Python Capture Agent for Opencast"
arch=('any')
url="https://github.com/opencast/pyCA"
license=('LGPL')
-depends=('gnutls' 'python-dateutil' 'python-configobj' 'python-flask' 'python-pycurl' 'python-sqlalchemy')
-optdepends=('gunicorn: wsgi web interface')
+depends=('python-pycurl' 'python-dateutil' 'python-configobj' 'python-sqlalchemy' 'python-sdnotify' 'python-psutil' 'python-flask')
+optdepends=('gunicorn: wsgi web interface' 'ffmpeg: video and audio recording')
source=("https://github.com/opencast/pyCA/archive/v$pkgver.tar.gz"
"pyca.install"
"pyca.service"
@@ -17,14 +17,14 @@ source=("https://github.com/opencast/pyCA/archive/v$pkgver.tar.gz"
"pyca-ingest.service"
"pyca-schedule.service")
install="pyca.install"
-md5sums=('c48f246eff3e33a04310da39c01578bf'
+md5sums=('9db4a8d30754458a624c23af1b1a7572'
'd16c4e1a394f0cf356f65555e8cb0334'
- 'c014533da3c3b9bb763419e2721e844a'
- '965c239a4c7a2d528f1ce559f8224ac7'
- '3d64e43407482b906b5e21f2a5584a6e'
- '2eb31065c6d4deb6888c3b187565add9'
- '4adcf6d8ff3641ad1dd4910a1957c9db'
- 'e86a4025da5842d701a12cc258116c66')
+ 'ad2dff096f5fd249f30137088ea5130d'
+ 'e00ff2fb7ded9f6ef2c01b6dccb8bb7c'
+ '00d4bc93ddd9de5226cbfad53e1b4d10'
+ 'eac3ed5d9f9766bcc4b455b69056b351'
+ 'e0ee6375752f98e3dfca8c9a5b2b776f'
+ 'f17d472d7de8f63e6b563fd38ac81314')
backup=('etc/pyca.conf')
prepare() {
@@ -46,9 +46,9 @@ package() {
install -Dm 644 "${srcdir}"/pyca-ui.service "${pkgdir}"/usr/lib/systemd/system/pyca-ui.service
install -dm 755 "${pkgdir}"/var/lib/pyca/recordings
- install -dm 755 "${pkgdir}"/usr/lib/python3.7/site-packages/pyca
+ install -dm 755 "${pkgdir}"/usr/lib/python3.8/site-packages/pyca
install -Dm 644 etc/pyca.conf "${pkgdir}"/etc/pyca.conf
- cp -dr --no-preserve=ownership pyca/* "${pkgdir}"/usr/lib/python3.7/site-packages/pyca/
+ cp -dr --no-preserve=ownership pyca/* "${pkgdir}"/usr/lib/python3.8/site-packages/pyca/
install -Dm 755 start.sh "${pkgdir}"/usr/bin/pyca
}
diff --git a/pyca-agentstate.service b/pyca-agentstate.service
index fde29d679329..cb0b113e2b4e 100644
--- a/pyca-agentstate.service
+++ b/pyca-agentstate.service
@@ -2,9 +2,13 @@
Description=Python Capture Agent agentstate service
Documentation=https://github.com/opencast/pyCA
Wants=network.target
+PartOf=pyca.service
+After=pyca.service
[Service]
-Type=simple
+Type=notify
+NotifyAccess=all
+WatchdogSec=300
User=pyca
ExecStart=/usr/bin/pyca agentstate
Restart=always
@@ -12,4 +16,4 @@ RestartSec=10
TimeoutSec=300
[Install]
-WantedBy=multi-user.target
+WantedBy=pyca.service
diff --git a/pyca-capture.service b/pyca-capture.service
index 5f6f091acbc8..a634fb143026 100644
--- a/pyca-capture.service
+++ b/pyca-capture.service
@@ -2,9 +2,13 @@
Description=Python Capture Agent capture service
Documentation=https://github.com/opencast/pyCA
Wants=network.target
+PartOf=pyca.service
+After=pyca.service
[Service]
-Type=simple
+Type=notify
+NotifyAccess=all
+WatchdogSec=300
User=pyca
ExecStart=/usr/bin/pyca capture
Restart=always
@@ -12,4 +16,4 @@ RestartSec=10
TimeoutSec=300
[Install]
-WantedBy=multi-user.target
+WantedBy=pyca.service
diff --git a/pyca-ingest.service b/pyca-ingest.service
index e1c542ac7763..83a626cb3bd6 100644
--- a/pyca-ingest.service
+++ b/pyca-ingest.service
@@ -2,9 +2,13 @@
Description=Python Capture Agent ingest service
Documentation=https://github.com/opencast/pyCA
Wants=network.target
+PartOf=pyca.service
+After=pyca.service
[Service]
-Type=simple
+Type=notify
+NotifyAccess=all
+WatchdogSec=3600
User=pyca
ExecStart=/usr/bin/pyca ingest
Restart=always
@@ -12,4 +16,4 @@ RestartSec=10
TimeoutSec=300
[Install]
-WantedBy=multi-user.target
+WantedBy=pyca.service
diff --git a/pyca-schedule.service b/pyca-schedule.service
index fe6435369e31..20524bde8c51 100644
--- a/pyca-schedule.service
+++ b/pyca-schedule.service
@@ -2,9 +2,13 @@
Description=Python Capture Agent schedule service
Documentation=https://github.com/opencast/pyCA
Wants=network.target
+PartOf=pyca.service
+After=pyca.service
[Service]
-Type=simple
+Type=notify
+NotifyAccess=all
+WatchdogSec=300
User=pyca
ExecStart=/usr/bin/pyca schedule
Restart=always
@@ -12,4 +16,4 @@ RestartSec=10
TimeoutSec=300
[Install]
-WantedBy=multi-user.target
+WantedBy=pyca.service
diff --git a/pyca-ui.service b/pyca-ui.service
index 209bbff0c414..d8053b02a000 100644
--- a/pyca-ui.service
+++ b/pyca-ui.service
@@ -2,13 +2,15 @@
Description=Python Capture Agent UI instance
Documentation=https://github.com/opencast/pyCA
Wants=network.target
+PartOf=pyca.service
+After=pyca.service
[Service]
Type=simple
User=pyca
-ExecStart=/usr/bin/gunicorn pyca.ui:app
+ExecStart=/usr/bin/python3 -m gunicorn.app.wsgiapp --config=/etc/pyca/gunicorn.conf.py pyca.ui:app
Restart=always
RestartSec=10
[Install]
-WantedBy=multi-user.target
+WantedBy=pyca.service
diff --git a/pyca.service b/pyca.service
index 7b997f2afefe..37a4aa059e85 100644
--- a/pyca.service
+++ b/pyca.service
@@ -1,16 +1,11 @@
[Unit]
-Description=Python Capture Agent
-Documentation=https://github.com/opencast/pyCA
-Wants=network.target
-PartOf=pyca.target
+Description=PyCA
[Service]
-Type=simple
-User=pyca
-ExecStart=/usr/bin/pyca
-Restart=always
-RestartSec=10
-TimeoutSec=300
+Type=oneshot
+ExecStart=/bin/true
+# Considered unit active after start
+RemainAfterExit=yes
[Install]
-WantedBy=pyca.target
+WantedBy=multi-user.target