summaryrefslogtreecommitdiff
path: root/net-mail/onionrouter
diff options
context:
space:
mode:
Diffstat (limited to 'net-mail/onionrouter')
-rw-r--r--net-mail/onionrouter/Manifest5
-rw-r--r--net-mail/onionrouter/files/onionrouter.service25
-rw-r--r--net-mail/onionrouter/metadata.xml8
-rw-r--r--net-mail/onionrouter/onionrouter-0.6.1.ebuild50
-rw-r--r--net-mail/onionrouter/onionrouter-9999.ebuild50
5 files changed, 138 insertions, 0 deletions
diff --git a/net-mail/onionrouter/Manifest b/net-mail/onionrouter/Manifest
new file mode 100644
index 000000000000..899ed9081e11
--- /dev/null
+++ b/net-mail/onionrouter/Manifest
@@ -0,0 +1,5 @@
+AUX onionrouter.service 462 BLAKE2B 83f048d1111167fd99ff2a3bfd791ac8435c01f9a262320ab260bf11d5b66b06453d2b4ea3176bfb6991f34c0d47bfeb5ccfcaafa21063aa4de7aeb0739d1c98 SHA512 8d84a028869a92f746b93eaa5ff6e1544a731893c96f223a67cd9fef8d15c00ba9922a6633e3e2d9cc094f722ccf7a3133ce923ef0b3478bf4e9d2d7d327ae11
+DIST onionrouter-0.6.1.tar.gz 26584 BLAKE2B e1d722ba4e7ec617e39fda54299cd71d9d47bbd34fd44a19ffef8f2349f9b238251b47d01c369223393a9d7f2e0a05c5d8b7dc9f991c7d386ba800086b8cc226 SHA512 5d08e7a7310e69e29eaba2098a62cef4b5044c207f4a78b4cfebfd2a9d18bd812b485793ff7395186d4949ad9604b4e82dc0e9b1200abf03108466bf531a6d15
+EBUILD onionrouter-0.6.1.ebuild 1162 BLAKE2B 14195482f1a67442979a5cc7daa6f513b3a3deb2a3801d6664f464793b28a04f64f991cfde7fe2405fd28e484f81814fb0ed742070028cf61e4a4f3a74287a6e SHA512 01b96089281280ef29c27f0a40d52ccb6f07dc707741e0b041b50533a3f636254bf6ba04e2b62f7404d9c2ab88377b3f428cb587ffd40bb0a783ec8af5534cab
+EBUILD onionrouter-9999.ebuild 1162 BLAKE2B 14195482f1a67442979a5cc7daa6f513b3a3deb2a3801d6664f464793b28a04f64f991cfde7fe2405fd28e484f81814fb0ed742070028cf61e4a4f3a74287a6e SHA512 01b96089281280ef29c27f0a40d52ccb6f07dc707741e0b041b50533a3f636254bf6ba04e2b62f7404d9c2ab88377b3f428cb587ffd40bb0a783ec8af5534cab
+MISC metadata.xml 248 BLAKE2B 3f65c2f88989989e697a91f6cdd53f41417682b0fdd13820473e04af6cbe434120f2e29e7b08edb18b860b50caf9131f8a69f396e64b85ba10901498cbf2587d SHA512 4784715e9b0407de4537918eb1f7879ab399491e47aa5256dc444fbf13a939a44a591e6f1775992576c082d9e5d0dadce8a968a70fa0f05ca4b17b6aea3e4ac3
diff --git a/net-mail/onionrouter/files/onionrouter.service b/net-mail/onionrouter/files/onionrouter.service
new file mode 100644
index 000000000000..bf5d7811f823
--- /dev/null
+++ b/net-mail/onionrouter/files/onionrouter.service
@@ -0,0 +1,25 @@
+[Unit]
+Description=onionrouter
+After=network.target tor.service
+Before=postfix.service
+
+[Service]
+ExecStart=/usr/bin/onionrouter
+Restart=on-failure
+RestartSec=10s
+DynamicUser=true
+PrivateDevices=true
+PrivateUsers=true
+ProtectClock=true
+ProtectControlGroups=true
+ProtectHome=true
+ProtectKernelLogs=true
+ProtectKernelModules=true
+ProtectKernelTunables=true
+ProtectHostname=true
+RestrictRealtime=true
+MemoryDenyWriteExecute=true
+
+[Install]
+WantedBy=default.target
+
diff --git a/net-mail/onionrouter/metadata.xml b/net-mail/onionrouter/metadata.xml
new file mode 100644
index 000000000000..fbb8d54dbc4d
--- /dev/null
+++ b/net-mail/onionrouter/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>candrews@gentoo.org</email>
+ <name>Craig Andrews</name>
+ </maintainer>
+</pkgmetadata>
diff --git a/net-mail/onionrouter/onionrouter-0.6.1.ebuild b/net-mail/onionrouter/onionrouter-0.6.1.ebuild
new file mode 100644
index 000000000000..2efd032bc84b
--- /dev/null
+++ b/net-mail/onionrouter/onionrouter-0.6.1.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{7,8,9} )
+DISTUTILS_SINGLE_IMPL=1
+DISTUTILS_USE_SETUPTOOLS=rdepend
+
+inherit distutils-r1 systemd
+
+DESCRIPTION=".onion discovery via SRV DNS lookups for use with postfix"
+HOMEPAGE="https://pypi.org/project/onionrouter/ https://github.com/ehloonion/onionrouter/"
+if [[ ${PV} == *9999 ]] ; then
+ SRC_URI=""
+ EGIT_REPO_URI="https://github.com/ehloonion/onionrouter.git"
+ inherit git-r3
+else
+ KEYWORDS="~amd64"
+ SRC_URI="https://pypi.io/packages/source/${PN::1}/${PN}/${P}.tar.gz"
+fi
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+LICENSE="GPL-3+"
+SLOT="0"
+
+RDEPEND="$(python_gen_cond_dep '
+ dev-python/dnspython[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+')"
+BDEPEND="$(python_gen_cond_dep '
+ test? (
+ dev-python/pytest[${PYTHON_USEDEP}]
+ dev-python/wheel[${PYTHON_USEDEP}]
+ )
+')"
+
+distutils_enable_tests pytest
+
+src_prepare() {
+ distutils-r1_src_prepare
+}
+
+src_install() {
+ distutils-r1_src_install
+ systemd_dounit "${FILESDIR}/${PN}.service"
+ insinto /etc/onionrouter
+ doins "${S}/onionrouter/configs/onionrouter.ini"
+}
diff --git a/net-mail/onionrouter/onionrouter-9999.ebuild b/net-mail/onionrouter/onionrouter-9999.ebuild
new file mode 100644
index 000000000000..2efd032bc84b
--- /dev/null
+++ b/net-mail/onionrouter/onionrouter-9999.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{7,8,9} )
+DISTUTILS_SINGLE_IMPL=1
+DISTUTILS_USE_SETUPTOOLS=rdepend
+
+inherit distutils-r1 systemd
+
+DESCRIPTION=".onion discovery via SRV DNS lookups for use with postfix"
+HOMEPAGE="https://pypi.org/project/onionrouter/ https://github.com/ehloonion/onionrouter/"
+if [[ ${PV} == *9999 ]] ; then
+ SRC_URI=""
+ EGIT_REPO_URI="https://github.com/ehloonion/onionrouter.git"
+ inherit git-r3
+else
+ KEYWORDS="~amd64"
+ SRC_URI="https://pypi.io/packages/source/${PN::1}/${PN}/${P}.tar.gz"
+fi
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+LICENSE="GPL-3+"
+SLOT="0"
+
+RDEPEND="$(python_gen_cond_dep '
+ dev-python/dnspython[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+')"
+BDEPEND="$(python_gen_cond_dep '
+ test? (
+ dev-python/pytest[${PYTHON_USEDEP}]
+ dev-python/wheel[${PYTHON_USEDEP}]
+ )
+')"
+
+distutils_enable_tests pytest
+
+src_prepare() {
+ distutils-r1_src_prepare
+}
+
+src_install() {
+ distutils-r1_src_install
+ systemd_dounit "${FILESDIR}/${PN}.service"
+ insinto /etc/onionrouter
+ doins "${S}/onionrouter/configs/onionrouter.ini"
+}