From 8614410fff311b8af5e58ba2d36e135be78186f8 Mon Sep 17 00:00:00 2001 From: octeep Date: Fri, 1 Apr 2022 17:55:08 +0100 Subject: [PATCH] New package: wireproxy-1.0.1 --- srcpkgs/wireproxy/files/wireproxy/run | 7 ++++++ srcpkgs/wireproxy/template | 31 +++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 srcpkgs/wireproxy/files/wireproxy/run create mode 100644 srcpkgs/wireproxy/template diff --git a/srcpkgs/wireproxy/files/wireproxy/run b/srcpkgs/wireproxy/files/wireproxy/run new file mode 100644 index 000000000000..7ba16434072e --- /dev/null +++ b/srcpkgs/wireproxy/files/wireproxy/run @@ -0,0 +1,7 @@ +#!/bin/sh + +[ -r ./conf ] && . ./conf + +export HOME=/var/lib/wireproxy + +exec chpst -u _wireproxy wireproxy --config ${CONFFILE:-/etc/wireproxy/config} diff --git a/srcpkgs/wireproxy/template b/srcpkgs/wireproxy/template new file mode 100644 index 000000000000..2acef4c59845 --- /dev/null +++ b/srcpkgs/wireproxy/template @@ -0,0 +1,31 @@ +# Template file for 'wireproxy' +pkgname=wireproxy +version=1.0.1 +revision=1 +build_style=go +go_import_path="github.com/octeep/wireproxy" +go_package="${go_import_path}/cmd/wireproxy" +short_desc="Wireguard client that exposes itself as a socks5 proxy" +maintainer="Wind Wong " +license="ISC" +homepage="https://github.com/octeep/wireproxy" +distfiles="https://github.com/octeep/wireproxy/archive/v${version}.tar.gz" +checksum=e21eac22ef1b12dc2d7b3e5b58dcff183af9c1547be3e55a7e6c71394f053e1e + +system_accounts="_wireproxy" +_wireproxy_homedir="/var/lib/wireproxy" + +conf_files="/etc/wireproxy/config" + +make_dirs=" + /etc/wireproxy 0750 root _wireproxy + /var/lib/wireproxy 0700 _wireproxy _wireproxy" + +post_install() { + vsv wireproxy + + printf "\n" > config + vinstall config 644 etc/wireproxy + + vlicense LICENSE +}