summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean Lucas2018-06-15 20:59:43 -0400
committerJean Lucas2018-06-15 20:59:43 -0400
commited99bcb5f9f0002bc49337d7b6805c4b1141b9f5 (patch)
tree8baa0ef3c88aad74d6696dde4947e8b05a103163
downloadaur-ed99bcb5f9f0002bc49337d7b6805c4b1141b9f5.tar.gz
Initial commit
-rw-r--r--.SRCINFO23
-rw-r--r--PKGBUILD36
-rw-r--r--filtron.service19
3 files changed, 78 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..e4d755d42398
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+# Generated by mksrcinfo v8
+# Sat Jun 16 00:59:32 UTC 2018
+pkgbase = filtron-git
+ pkgdesc = Filtering reverse HTTP proxy
+ pkgver = 0+51+93f8b22
+ pkgrel = 1
+ url = https://github.com/asciimoo/filtron
+ arch = any
+ license = AGPL3
+ makedepends = git
+ makedepends = go
+ optdepends = searx: A privacy-respecting, hackable metasearch engine
+ optdepends = searx-git: A privacy-respecting, hackable metasearch engine (Git)
+ optdepends = morty: Privacy-aware web content sanitizer proxy-as-a-service
+ optdepends = morty-git: Privacy-aware web content sanitizer proxy-as-a-service (Git)
+ conflicts = filtron
+ source = git+https://github.com/asciimoo/filtron.git
+ source = filtron.service
+ sha512sums = SKIP
+ sha512sums = 0b7bbe55b3fd89d589e5662699f93d7aaf3c1d77d29be9cc568f8430e4a2491ba4920ca153f4d887a29da1f51670ec06346809cc5d1f373af540e252feccc799
+
+pkgname = filtron-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..c7db3a59b492
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,36 @@
+# Maintainer: Jean Lucas <jean@4ray.co>
+
+pkgname=filtron-git
+pkgver=0+51+93f8b22
+pkgrel=1
+pkgdesc='Filtering reverse HTTP proxy'
+arch=(any)
+url='https://github.com/asciimoo/filtron'
+license=(AGPL3)
+conflicts=(filtron)
+makedepends=(git go)
+optdepends=('searx: A privacy-respecting, hackable metasearch engine'
+ 'searx-git: A privacy-respecting, hackable metasearch engine (Git)'
+ 'morty: Privacy-aware web content sanitizer proxy-as-a-service'
+ 'morty-git: Privacy-aware web content sanitizer proxy-as-a-service (Git)')
+source=(git+https://github.com/asciimoo/filtron.git
+ filtron.service)
+sha512sums=(SKIP
+ 0b7bbe55b3fd89d589e5662699f93d7aaf3c1d77d29be9cc568f8430e4a2491ba4920ca153f4d887a29da1f51670ec06346809cc5d1f373af540e252feccc799)
+
+pkgver() {
+ cd $srcdir/filtron
+ printf 0+%s+%s $(git rev-list --count HEAD) $(git rev-parse --short HEAD)
+}
+
+build() {
+ cd $srcdir/filtron
+ GOPATH=$srcdir/filtron go get -v -x github.com/asciimoo/filtron
+}
+
+package() {
+ cd $srcdir/filtron
+ install -D bin/filtron $pkgdir/usr/bin/filtron
+ install -Dm 644 ../filtron.service $pkgdir/usr/lib/systemd/system/filtron.service
+ install -Dm 644 LICENSE $pkgdir/usr/share/licenses/filtron/LICENSE
+}
diff --git a/filtron.service b/filtron.service
new file mode 100644
index 000000000000..9f2a84587741
--- /dev/null
+++ b/filtron.service
@@ -0,0 +1,19 @@
+[Unit]
+Description=Filtron instance
+After=network.target
+
+[Service]
+Type=simple
+User=nobody
+PrivateTmp=true
+PrivateDevices=true
+# Prevent access to /home, /root, and /run/user
+ProtectHome=true
+# Prevent writes to /usr, /boot, and /etc
+ProtectSystem=full
+ExecStart=/usr/bin/filtron -listen 127.0.0.1:4004 -rules /etc/filtron/rules.json -target 127.0.0.1:8888
+Restart=on-failure
+RestartSec=1
+
+[Install]
+WantedBy=multi-user.target