commit:     15f6ed08dab0f1f0c1c43ec6f3935d62c5752a1a
Author:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
AuthorDate: Tue Jul  4 22:37:51 2023 +0000
Commit:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
CommitDate: Wed Jul  5 20:29:55 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=15f6ed08

net-dns/inadyn: new package, add 2.11.0

It's a suggested alternate to net-dns/ddclient according to upstream.

Bug: https://bugs.gentoo.org/909646
Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>

 net-dns/inadyn/Manifest               |  1 +
 net-dns/inadyn/files/inadyn.confd     |  5 +++
 net-dns/inadyn/files/inadyn.initd     | 23 +++++++++++++
 net-dns/inadyn/files/inadyn.tmpfilesd |  2 ++
 net-dns/inadyn/inadyn-2.11.0.ebuild   | 61 +++++++++++++++++++++++++++++++++++
 net-dns/inadyn/metadata.xml           | 25 ++++++++++++++
 6 files changed, 117 insertions(+)

diff --git a/net-dns/inadyn/Manifest b/net-dns/inadyn/Manifest
new file mode 100644
index 000000000000..f3b8a617a043
--- /dev/null
+++ b/net-dns/inadyn/Manifest
@@ -0,0 +1 @@
+DIST inadyn-2.11.0.tar.gz 509655 BLAKE2B 
7acb356f691717e282355ed9f0a152463f2364633b0e999838572b18b3330b4aa6cc1f02c58ed1f0fac4e6bac6220992f0c7b20449aea420eb28f55343caa954
 SHA512 
d0d73cbecbc4dca028dd39f4e125ed9f5e370cb8367086cc819eafbae825ce7bb6f2ad4a5134bfefefd7d6609352d6355b73b28149426a8f755b0e463aa8f008

diff --git a/net-dns/inadyn/files/inadyn.confd 
b/net-dns/inadyn/files/inadyn.confd
new file mode 100644
index 000000000000..89c550d5f48d
--- /dev/null
+++ b/net-dns/inadyn/files/inadyn.confd
@@ -0,0 +1,5 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+# Additional passed opts for In-a-Dyn
+INADYN_OPTS=""

diff --git a/net-dns/inadyn/files/inadyn.initd 
b/net-dns/inadyn/files/inadyn.initd
new file mode 100644
index 000000000000..9b93663fd80c
--- /dev/null
+++ b/net-dns/inadyn/files/inadyn.initd
@@ -0,0 +1,23 @@
+#!/sbin/openrc-run
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+config="/etc/inadyn.conf"
+description="Dynamic DNS client"
+name="In-a-Dyn"
+pidfile="/run/inadyn/inadyn.pid"
+
+command="/usr/sbin/inadyn"
+command_group="inadyn"
+command_user="inadyn"
+command_args="--drop-privs=${command_user}:${command_group} 
--pidfile=${pidfile} ${INADYN_OPTS}"
+
+start_pre() {
+       if [ ! -f "${config}" ]; then
+               eerror "Please create ${config} before starting In-a-Dyn!"
+               return 1
+       else
+               checkpath -f -m 600 -o "${command_user}:${command_group}" -q 
"${config}"
+               return 0
+       fi
+}

diff --git a/net-dns/inadyn/files/inadyn.tmpfilesd 
b/net-dns/inadyn/files/inadyn.tmpfilesd
new file mode 100644
index 000000000000..702ca17ae3b4
--- /dev/null
+++ b/net-dns/inadyn/files/inadyn.tmpfilesd
@@ -0,0 +1,2 @@
+# inadyn runtime directory for pid file
+d /run/inadyn 0755 inadyn inadyn -

diff --git a/net-dns/inadyn/inadyn-2.11.0.ebuild 
b/net-dns/inadyn/inadyn-2.11.0.ebuild
new file mode 100644
index 000000000000..810c370d095d
--- /dev/null
+++ b/net-dns/inadyn/inadyn-2.11.0.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit systemd tmpfiles
+
+DESCRIPTION="Dynamic DNS client with multiple SSL/TLS library support"
+HOMEPAGE="https://github.com/troglobit/inadyn";
+SRC_URI="https://github.com/troglobit/inadyn/releases/download/v${PV}/${P}.tar.gz";
+
+LICENSE="GPL-2+"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="gnutls mbedtls openssl"
+REQUIRED_USE="?? ( gnutls mbedtls openssl )"
+
+DEPEND="
+       acct-group/inadyn
+       acct-user/inadyn
+       dev-libs/confuse:=
+       gnutls? (
+               dev-libs/nettle:=
+               net-libs/gnutls:0=
+       )
+       mbedtls? ( net-libs/mbedtls:0= )
+       openssl? ( dev-libs/openssl:0= )
+"
+RDEPEND="${DEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+src_configure() {
+       local myeconfargs=( "--disable-ssl" )
+       if use gnutls || use mbedtls || use openssl; then
+               local myeconfargs=( "--enable-ssl" )
+       fi
+
+       use mbedtls && myeconfargs+=( "--enable-mbedtls" )
+       use openssl && myeconfargs+=( "--enable-openssl" )
+
+       myeconfargs+=( --with-systemd="$(systemd_get_systemunitdir)" )
+
+       econf "${myeconfargs[@]}"
+}
+
+src_install() {
+       default
+
+       insinto /etc
+       insopts -m 0600 -o inadyn -g inadyn
+       doins examples/inadyn.conf
+
+       newinitd "${FILESDIR}"/inadyn.initd inadyn
+       newconfd "${FILESDIR}"/inadyn.confd inadyn
+
+       newtmpfiles "${FILESDIR}"/inadyn.tmpfilesd inadyn.conf
+}
+
+pkg_postinst() {
+       tmpfiles_process inadyn.conf
+}

diff --git a/net-dns/inadyn/metadata.xml b/net-dns/inadyn/metadata.xml
new file mode 100644
index 000000000000..e1ffc52abaa4
--- /dev/null
+++ b/net-dns/inadyn/metadata.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+       <maintainer type="person">
+               <email>conik...@gentoo.org</email>
+               <name>Conrad Kostecki</name>
+       </maintainer>
+       <longdescription>
+               Inadyn, or In-a-Dyn, is a small and simple Dynamic DNS,
+               DDNS, client with HTTPS support. Commonly available in
+               many GNU/Linux distributions, used in off the shelf routers
+               and Internet gateways to automate the task of keeping your
+               Internet name in sync with your public IP address.
+               It can also be used in installations with redundant (backup)
+               connections to the Internet.
+       </longdescription>
+       <use>
+               <flag name="mbedtls">Use <pkg>net-libs/mbedtls</pkg> as tls 
provider.</flag>
+               <flag name="openssl">Use <pkg>dev-libs/openssl</pkg> as tls 
provider.</flag>
+       </use>
+       <upstream>
+               <bugs-to>https://github.com/troglobit/inadyn/issues</bugs-to>
+               <remote-id type="github">troglobit/inadyn</remote-id>
+       </upstream>
+</pkgmetadata>

Reply via email to