summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorVVL2018-06-19 20:13:43 +0300
committerVVL2018-06-19 20:13:43 +0300
commit55e1b421ee203efe6b55654496d2bca4e2368342 (patch)
tree51645226f3eea0ecb2b0ad17555ea0f777d9051c
downloadaur-55e1b421ee203efe6b55654496d2bca4e2368342.tar.gz
Initial release
-rw-r--r--.SRCINFO18
-rw-r--r--PKGBUILD23
-rw-r--r--mtprotoproxy.service15
3 files changed, 56 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..e565a0d3bd8c
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,18 @@
+# Generated by mksrcinfo v8
+# Tue Jun 19 17:12:36 UTC 2018
+pkgbase = mtprotoproxy
+ pkgdesc = Telegram MTProto proxy written in pure python
+ pkgver = 0.9
+ pkgrel = 1
+ url = https://github.com/alexbers/mtprotoproxy
+ arch = any
+ license = MIT
+ depends = python
+ depends = python-pycryptodome
+ source = https://github.com/alexbers/mtprotoproxy/archive/v0.9.tar.gz
+ source = mtprotoproxy.service
+ sha256sums = bf81b5c33c190b314fe19a2bfe490a005ceb91f84285c037b8f1c14da85020bd
+ sha256sums = cd993b52610d68361a3faf9500b744f5d5e4e8eb3e79effc36098576f24b950c
+
+pkgname = mtprotoproxy
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..97cc6f0d301f
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,23 @@
+# Maintainer: VVL <me@ivvl.ru>
+# Contributor: VVL <me@ivvl.ru>
+
+pkgname=mtprotoproxy
+pkgver=0.9
+pkgrel=1
+pkgdesc="Telegram MTProto proxy written in pure python"
+arch=(any)
+url="https://github.com/alexbers/mtprotoproxy"
+license=('MIT')
+source=("https://github.com/alexbers/mtprotoproxy/archive/v$pkgver.tar.gz"
+ "mtprotoproxy.service")
+depends=('python' 'python-pycryptodome')
+sha256sums=('bf81b5c33c190b314fe19a2bfe490a005ceb91f84285c037b8f1c14da85020bd'
+ 'cd993b52610d68361a3faf9500b744f5d5e4e8eb3e79effc36098576f24b950c')
+package() {
+ cd "$pkgname-$pkgver"
+ install -Dm755 "mtprotoproxy.py" "$pkgdir/usr/bin/mtprotoproxy"
+ install -Dm644 config.py "$pkgdir/etc/mtprotoproxy.conf"
+ install -Dm644 README.md -t "$pkgdir/usr/share/docs/$pkgname"
+ install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
+ install -Dm644 "$srcdir/mtprotoproxy.service" "$pkgdir/etc/systemd/system/mtprotoproxy.service"
+}
diff --git a/mtprotoproxy.service b/mtprotoproxy.service
new file mode 100644
index 000000000000..2e37552d9503
--- /dev/null
+++ b/mtprotoproxy.service
@@ -0,0 +1,15 @@
+[Unit]
+Description=Telegram MTProto proxy written in pure python
+After=network.target network-online.target
+
+[Service]
+Type=simple
+User=nobody
+ExecStart=/usr/bin/mtprotoproxy /etc/mtprotoproxy.conf
+Restart=always
+RestartSec=10
+NoNewPrivileges=true
+AmbientCapabilities=CAP_NET_BIND_SERVICE CAP_NET_ADMIN
+
+[Install]
+WantedBy=multi-user.target