diff options
author | Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in> | 2023-04-07 00:44:03 +0500 |
---|---|---|
committer | Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in> | 2023-04-07 00:49:55 +0500 |
commit | c84a69af155cdf3247f26f46e4ae121aa6779767 (patch) | |
tree | fd69d7dc6b0a1d71b98703e6e1135fb330c0a664 /net-proxy/snowflake | |
parent | net-misc/tuba: Wrong email address fix (diff) | |
download | guru-c84a69af155cdf3247f26f46e4ae121aa6779767.tar.gz guru-c84a69af155cdf3247f26f46e4ae121aa6779767.tar.bz2 guru-c84a69af155cdf3247f26f46e4ae121aa6779767.zip |
net-proxy/snowflake: new package, add 2.5.1
Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in>
Diffstat (limited to 'net-proxy/snowflake')
-rw-r--r-- | net-proxy/snowflake/Manifest | 1 | ||||
-rw-r--r-- | net-proxy/snowflake/files/snowflake-proxy.initd | 15 | ||||
-rw-r--r-- | net-proxy/snowflake/files/snowflake-proxy.service | 16 | ||||
-rw-r--r-- | net-proxy/snowflake/metadata.xml | 16 | ||||
-rw-r--r-- | net-proxy/snowflake/snowflake-2.5.1.ebuild | 48 |
5 files changed, 96 insertions, 0 deletions
diff --git a/net-proxy/snowflake/Manifest b/net-proxy/snowflake/Manifest new file mode 100644 index 000000000..fd29177a3 --- /dev/null +++ b/net-proxy/snowflake/Manifest @@ -0,0 +1 @@ +DIST snowflake-2.5.1.tar.gz 17989511 BLAKE2B 5d254e483803d0c03121acb12a188250eee79aec1af69d22bc88600ce5ffb67af09e437998a072977e6c9437b3fe5612e84663a90be66fb370eebf10f03327e2 SHA512 270eefa3cc999db36118871d23b2beebf4ef002c23e4c6a41e33bfa25a9c51c0305d2b8ad01f34863001ac5f822a9d97496249e2a4c0ae5c1a7af58cc56c26a4 diff --git a/net-proxy/snowflake/files/snowflake-proxy.initd b/net-proxy/snowflake/files/snowflake-proxy.initd new file mode 100644 index 000000000..8818c6a85 --- /dev/null +++ b/net-proxy/snowflake/files/snowflake-proxy.initd @@ -0,0 +1,15 @@ +#!/sbin/openrc-run +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 +# +# shellcheck shell=sh + +command="/usr/bin/snowflake-proxy" +command_args="${SNOWFLAKE_PROXY_OPTS}" +command_background=1 +command_user="nobody:nobody" +pidfile="/run/snowflake-proxy.pid" + +depend() { + need net +} diff --git a/net-proxy/snowflake/files/snowflake-proxy.service b/net-proxy/snowflake/files/snowflake-proxy.service new file mode 100644 index 000000000..d023d5714 --- /dev/null +++ b/net-proxy/snowflake/files/snowflake-proxy.service @@ -0,0 +1,16 @@ +[Unit] +Description=Snowflake Proxy +Documentation=man:snowflake-proxy +Documentation=https://snowflake.torproject.org/ +After=network-online.target nss-lookup.target +Wants=network-online.target + +[Service] +ExecStart=/usr/bin/snowflake-proxy +Restart=on-failure + +DynamicUser=true +NoNewPrivileges=true + +[Install] +WantedBy=multi-user.target diff --git a/net-proxy/snowflake/metadata.xml b/net-proxy/snowflake/metadata.xml new file mode 100644 index 000000000..85cf7c4b7 --- /dev/null +++ b/net-proxy/snowflake/metadata.xml @@ -0,0 +1,16 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>cyber+gentoo@sysrq.in</email> + <name>Anna</name> + </maintainer> + <upstream> + <bugs-to>https://anonticket.onionize.space/</bugs-to> + </upstream> + <use> + <flag name="client">Build the client application</flag> + <flag name="server">Build the server application</flag> + <flag name="proxy">Build standalone proxy application</flag> + </use> +</pkgmetadata> diff --git a/net-proxy/snowflake/snowflake-2.5.1.ebuild b/net-proxy/snowflake/snowflake-2.5.1.ebuild new file mode 100644 index 000000000..fa82ac8eb --- /dev/null +++ b/net-proxy/snowflake/snowflake-2.5.1.ebuild @@ -0,0 +1,48 @@ +# Copyright 2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit go-module systemd + +JOB_ID="222736" +DESCRIPTION="Pluggable Transport using WebRTC, inspired by Flashproxy" +HOMEPAGE=" + https://snowflake.torproject.org/ + https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/snowflake +" +SRC_URI="https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/${PN}/-/jobs/${JOB_ID}/artifacts/raw/${P}.tar.gz" + +LICENSE="Apache-2.0 BSD BSD-2 CC0-1.0 MIT" +SLOT="0" +KEYWORDS="~amd64" + +COMPONENTS=( broker client probetest proxy server ) + +src_compile() { + for component in "${COMPONENTS[@]}"; do + pushd ${component} || die + einfo "Building ${component}" + ego build + popd || die + done +} + +src_test() { + ego test ./... +} + +src_install() { + local component + for component in "${COMPONENTS[@]}"; do + newbin ${component}/${component} snowflake-${component} + newdoc ${component}/README.md README_${component}.md + done + + systemd_dounit "${FILESDIR}"/snowflake-proxy.service + newinitd "${FILESDIR}"/snowflake-proxy.initd snowflake-proxy + + einstalldocs + dodoc doc/*.txt doc/*.md + doman doc/*.1 +} |