summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorSherlock Holo2018-02-28 21:16:32 +0800
committerSherlock Holo2018-02-28 21:16:32 +0800
commit11f407b3e1a289a9e0487a187ecb86ea29f8566a (patch)
treeabbd42dfdd4729e199c943c3261451065523d404
downloadaur-11f407b3e1a289a9e0487a187ecb86ea29f8566a.tar.gz
Add ktproxy package
-rw-r--r--.SRCINFO24
-rw-r--r--PKGBUILD34
-rw-r--r--ktproxy-client3
-rw-r--r--ktproxy-client@.service11
-rw-r--r--ktproxy-server3
-rw-r--r--ktproxy-server@.service11
6 files changed, 86 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..fd8389bf6a82
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,24 @@
+pkgbase = ktproxy
+ pkgdesc = a websocket like proxy by kotlin
+ pkgver = 0.1
+ pkgrel = 1
+ url = https://github.com/Sherlock-Holo/ktproxy
+ arch = x86_64
+ arch = i686
+ license = MPL
+ depends = java-runtime>=9
+ source = https://github.com/Sherlock-Holo/ktproxy/releases/download/0.1/ktproxy-client.jar
+ source = https://github.com/Sherlock-Holo/ktproxy/releases/download/0.1/ktproxy-server.jar
+ source = ktproxy-client
+ source = ktproxy-server
+ source = ktproxy-client@.service
+ source = ktproxy-server@.service
+ md5sums = dd5aefe44befca7c44056d3761f697e4
+ md5sums = 168abbc4cb4c4a3f0cca7eb8d04e1ded
+ md5sums = 03faf6ae95f1865fa42bcae69e9cf071
+ md5sums = 79e2a773c9e1b7140b04c9de8bb84a17
+ md5sums = 0d7a86dee623d84e4c4cabce9a2cfcbf
+ md5sums = 79a4cc48053bcf5633ed647dbb20be44
+
+pkgname = ktproxy
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..2f9714bd1e27
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,34 @@
+# Maintainer: Sherlock-Holo <sherlockya@gmail.com>
+
+pkgname=ktproxy
+pkgver=0.1
+pkgrel=1
+pkgdesc="a websocket like proxy by kotlin"
+url="https://github.com/Sherlock-Holo/$pkgname"
+arch=('x86_64' 'i686')
+license=('MPL')
+depends=('java-runtime>=9')
+source=("https://github.com/Sherlock-Holo/ktproxy/releases/download/0.1/ktproxy-client.jar"
+ "https://github.com/Sherlock-Holo/ktproxy/releases/download/0.1/ktproxy-server.jar"
+ "ktproxy-client"
+ "ktproxy-server"
+ "ktproxy-client@.service"
+ "ktproxy-server@.service")
+md5sums=('dd5aefe44befca7c44056d3761f697e4'
+ '168abbc4cb4c4a3f0cca7eb8d04e1ded'
+ '03faf6ae95f1865fa42bcae69e9cf071'
+ '79e2a773c9e1b7140b04c9de8bb84a17'
+ '0d7a86dee623d84e4c4cabce9a2cfcbf'
+ '79a4cc48053bcf5633ed647dbb20be44')
+
+package(){
+ mkdir -p $pkgdir/opt/ktproxy
+ mkdir -p $pkgdir/usr/bin
+ mkdir -p $pkgdir/usr/lib/systemd/system
+
+ install -Dm644 $srcdir/ktproxy-{client,server}.jar $pkgdir/opt/ktproxy
+
+ install -Dm755 $srcdir/ktproxy-{client,server} $pkgdir/usr/bin
+
+ install -Dm644 $srcdir/ktproxy-{client,server}@.service $pkgdir/usr/lib/systemd/system
+}
diff --git a/ktproxy-client b/ktproxy-client
new file mode 100644
index 000000000000..2386feca7eef
--- /dev/null
+++ b/ktproxy-client
@@ -0,0 +1,3 @@
+#!/usr/bin/bash
+
+java -jar /opt/ktproxy/ktproxy-client.jar
diff --git a/ktproxy-client@.service b/ktproxy-client@.service
new file mode 100644
index 000000000000..7c44743bb61f
--- /dev/null
+++ b/ktproxy-client@.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=ktproxy service
+After=network.target
+
+[Service]
+ExecStart=/usr/bin/ktproxy-client -c /etc/ktproxy/%i.toml
+MemoryAccounting=true
+
+[Install]
+WantedBy=multi-user.target
+
diff --git a/ktproxy-server b/ktproxy-server
new file mode 100644
index 000000000000..8a44fd34b028
--- /dev/null
+++ b/ktproxy-server
@@ -0,0 +1,3 @@
+#!/usr/bin/bash
+
+java -jar /opt/ktproxy/ktproxy-server.jar
diff --git a/ktproxy-server@.service b/ktproxy-server@.service
new file mode 100644
index 000000000000..cfaf14ca4b46
--- /dev/null
+++ b/ktproxy-server@.service
@@ -0,0 +1,11 @@
+[Unit]
+Description=ktproxy service
+After=network.target
+
+[Service]
+ExecStart=/usr/bin/ktproxy-server -c /etc/ktproxy/%i.toml
+MemoryAccounting=true
+
+[Install]
+WantedBy=multi-user.target
+