summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorYuval Adam2015-11-14 12:52:11 +0200
committerYuval Adam2015-11-14 12:52:11 +0200
commitc3e732caed3b257f70ec6048b657774c16f0bf6a (patch)
tree6073152e2274fb8ff4436e4d73c769145639828d
parent874e9cb5eec5b61fb32d72c53cc81cf61863369b (diff)
downloadaur-c3e732caed3b257f70ec6048b657774c16f0bf6a.tar.gz
Add proper fr24feed directories and configs
-rw-r--r--.SRCINFO9
-rw-r--r--PKGBUILD25
-rw-r--r--flightradar24.install8
-rw-r--r--flightradar24.sysusers1
-rw-r--r--flightradar24.tmpfiles2
-rw-r--r--fr24feed.service16
6 files changed, 55 insertions, 6 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 589d8c28559..7accafc90aa 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,8 +1,9 @@
pkgbase = flightradar24
pkgdesc = Feeder software for Flightradar24.com
pkgver = 1.0.13
- pkgrel = 4
+ pkgrel = 5
url = http://forum.flightradar24.com/threads/7563-Flightradar24-decoder-feeder-BETA-testing-%28Win-RPi-Linux-OSX%29
+ install = flightradar24.install
arch = x86_64
arch = i686
arch = armv6h
@@ -10,6 +11,12 @@ pkgbase = flightradar24
license = unknown
depends = zlib
depends = gcc-libs
+ source = fr24feed.service
+ source = flightradar24.tmpfiles
+ source = flightradar24.sysusers
+ sha256sums = 42488de23b25a9f8c3586a1f834972d54ddb669867a27c641b55c718459a841d
+ sha256sums = 32f6f289efe8e3e303767239b2a276405b2d7c0fcbbde8ed9473ee6889b676ff
+ sha256sums = 7e5e1a28769559a2e2e1312894a1f9d315c4812bb34e2f1c45b2f877e4f4eeb0
source_x86_64 = http://feed.flightradar24.com/linux/fr24feed_1.0.13-2_amd64.tgz
sha256sums_x86_64 = 71a43fd6de5e033af59ca989b85e7c724d3aace26eb11b629dab4088a3321f6c
source_i686 = http://feed.flightradar24.com/linux/fr24feed_1.0.13-2_i386.tgz
diff --git a/PKGBUILD b/PKGBUILD
index 390cdcfebd8..6ca1218c652 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,12 +2,20 @@
pkgname=flightradar24
pkgver=1.0.13
-pkgrel=4
+pkgrel=5
pkgdesc="Feeder software for Flightradar24.com"
url="http://forum.flightradar24.com/threads/7563-Flightradar24-decoder-feeder-BETA-testing-%28Win-RPi-Linux-OSX%29"
arch=('x86_64' 'i686' 'armv6h' 'armv7h')
license=('unknown')
depends=('zlib' 'gcc-libs')
+install=flightradar24.install
+
+source=(fr24feed.service flightradar24.tmpfiles flightradar24.sysusers)
+sha256sums=(
+ '42488de23b25a9f8c3586a1f834972d54ddb669867a27c641b55c718459a841d'
+ '32f6f289efe8e3e303767239b2a276405b2d7c0fcbbde8ed9473ee6889b676ff'
+ '7e5e1a28769559a2e2e1312894a1f9d315c4812bb34e2f1c45b2f877e4f4eeb0'
+)
source_i686=("http://feed.flightradar24.com/linux/fr24feed_${pkgver}-2_i386.tgz")
sha256sums_i686=('d5a59d2837a65334ab8ff760c749b4da5f721030f8b441dc28a5f4c20a56e2f9')
@@ -22,17 +30,24 @@ source_armv7h=("http://feed.flightradar24.com/raspberry-pi/fr24feed_${pkgver}-2_
sha256sums_armv7h=('ab54ce2ff14bceca43e28bec387d0309f8e64fe7853a6cbc6a1cb85110696ef1')
package() {
+ cd "$srcdir"
if [[ $CARCH = "i686" ]]; then
- cd "$srcdir/fr24feed_i386"
+ pushd fr24feed_i386
elif [[ $CARCH = "x86_64" ]]; then
- cd "$srcdir/fr24feed_amd64"
+ pushd fr24feed_amd64
elif [[ $CARCH = "armv6h" ]]; then
- cd "$srcdir/fr24feed_armv6l"
+ pushd fr24feed_armv6l
elif [[ $CARCH = "armv7h" ]]; then
- cd "$srcdir/fr24feed_armv7l"
+ pushd fr24feed_armv7l
fi
+
install -Dm755 fr24feed "$pkgdir/usr/bin/fr24feed"
install -Dm644 LICENSE.fr24feed "$pkgdir/usr/share/licenses/${pkgname}/LICENSE"
+ popd
+
+ install -Dm644 fr24feed.service "$pkgdir/usr/lib/systemd/system/fr24feed.service"
+ install -Dm644 flightradar24.tmpfiles "$pkgdir/usr/lib/tmpfiles.d/flightradar24.conf"
+ install -Dm644 flightradar24.sysusers "$pkgdir/usr/lib/sysusers.d/flightradar24.conf"
}
# vim:set ts=2 sw=2 et:
diff --git a/flightradar24.install b/flightradar24.install
new file mode 100644
index 00000000000..4158e20763d
--- /dev/null
+++ b/flightradar24.install
@@ -0,0 +1,8 @@
+post_install() {
+ systemd-sysusers flightradar24.conf
+ systemd-tmpfiles --create flightradar24.conf
+
+ echo "==> To signup and configure fr24feed, run"
+ echo "==> "
+ echo "==> sudo -u fr24 fr24feed --signup --config-file=/etc/fr24feed/fr24feed/ini"
+}
diff --git a/flightradar24.sysusers b/flightradar24.sysusers
new file mode 100644
index 00000000000..3407ca4101a
--- /dev/null
+++ b/flightradar24.sysusers
@@ -0,0 +1 @@
+u fr24 - "FlightRadar24 Client"
diff --git a/flightradar24.tmpfiles b/flightradar24.tmpfiles
new file mode 100644
index 00000000000..86f54a6ec87
--- /dev/null
+++ b/flightradar24.tmpfiles
@@ -0,0 +1,2 @@
+D /var/log/fr24feed 0755 fr24 fr24 -
+D /etc/fr24feed 0755 fr24 fr24 -
diff --git a/fr24feed.service b/fr24feed.service
new file mode 100644
index 00000000000..8b91c9364a2
--- /dev/null
+++ b/fr24feed.service
@@ -0,0 +1,16 @@
+[Unit]
+Description=Flightradar24 decoder and feeder
+After=network.target
+
+[Service]
+Restart=on-failure
+User=fr24feed
+ProtectSystem=full
+ProtectHome=true
+RuntimeDirectory=fr24feed
+
+ExecStart=/usr/bin/fr24feed --config-file=/etc/fr24feed/fr24feed.ini --logfile=/var/log/fr24feed/fr24feed.log
+
+[Install]
+WantedBy=network.target
+