mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-19 12:03:02 -04:00
net-proxy/snowflake: new package, add 2.5.1
Signed-off-by: Anna (cybertailor) Vyalkova <cyber+gentoo@sysrq.in>
This commit is contained in:
1
net-proxy/snowflake/Manifest
Normal file
1
net-proxy/snowflake/Manifest
Normal file
@@ -0,0 +1 @@
|
||||
DIST snowflake-2.5.1.tar.gz 17989511 BLAKE2B 5d254e483803d0c03121acb12a188250eee79aec1af69d22bc88600ce5ffb67af09e437998a072977e6c9437b3fe5612e84663a90be66fb370eebf10f03327e2 SHA512 270eefa3cc999db36118871d23b2beebf4ef002c23e4c6a41e33bfa25a9c51c0305d2b8ad01f34863001ac5f822a9d97496249e2a4c0ae5c1a7af58cc56c26a4
|
||||
15
net-proxy/snowflake/files/snowflake-proxy.initd
Normal file
15
net-proxy/snowflake/files/snowflake-proxy.initd
Normal file
@@ -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
|
||||
}
|
||||
16
net-proxy/snowflake/files/snowflake-proxy.service
Normal file
16
net-proxy/snowflake/files/snowflake-proxy.service
Normal file
@@ -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
|
||||
16
net-proxy/snowflake/metadata.xml
Normal file
16
net-proxy/snowflake/metadata.xml
Normal file
@@ -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>
|
||||
48
net-proxy/snowflake/snowflake-2.5.1.ebuild
Normal file
48
net-proxy/snowflake/snowflake-2.5.1.ebuild
Normal file
@@ -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
|
||||
}
|
||||
Reference in New Issue
Block a user