summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorgilcu32018-08-31 09:56:32 -0400
committergilcu32018-08-31 09:56:32 -0400
commita01844d68e266c94e204f7c53ef3951c4616a758 (patch)
treee7e324ef426970d49a6b8e7d8890cebb9d81d839
parent61b919e2e18f2da5cb71b26a8e2f8281c3adffca (diff)
downloadaur-a01844d68e266c94e204f7c53ef3951c4616a758.tar.gz
fixed issue with permission as non-root user as debated here https://github.com/shadowsocks/shadowsocks-libev/issues/1252
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD2
-rw-r--r--redsocks2.install6
3 files changed, 8 insertions, 2 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 35704711b45..0066e24b56d 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = redsocks2-git
pkgdesc = redsocks2 adapted to compile with openssl 1.0
pkgver = 0.66.r39.gc9618cd
- pkgrel = 2
+ pkgrel = 3
url = https://github.com/semigodking/redsocks
install = redsocks2.install
arch = i686
diff --git a/PKGBUILD b/PKGBUILD
index e163d2e2a7d..58eb8c2daef 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -5,7 +5,7 @@
pkgname=redsocks2-git
pkgver=0.66.r39.gc9618cd
-pkgrel=2
+pkgrel=3
pkgdesc='redsocks2 adapted to compile with openssl 1.0'
arch=('i686' 'x86_64')
url='https://github.com/semigodking/redsocks'
diff --git a/redsocks2.install b/redsocks2.install
index ed641f16a9e..b99e837d8e4 100644
--- a/redsocks2.install
+++ b/redsocks2.install
@@ -7,7 +7,12 @@ add_redsocks_user() {
}
post_install() {
+ setcap cap_net_bind_service,cap_net_admin+ep usr/bin/redsocks2 2>/dev/null
+}
+
+post_install() {
add_redsocks_user
+ post_install
cat << EOF
To launch redsocks2:
@@ -24,6 +29,7 @@ EOF
post_upgrade() {
add_redsocks_user
+ post_install
}
post_remove() {