summaryrefslogtreecommitdiff
path: root/net-dns/coredns
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2023-11-10 22:34:27 +0000
committerV3n3RiX <venerix@koprulu.sector>2023-11-10 22:34:27 +0000
commit04b35f566703f8bb84d52e8d2ff2f0f54c21900b (patch)
tree8c04f83d8fb3c828c1eea4e4bc7ac14a4e902661 /net-dns/coredns
parenta6611f9bc959724ec73dbaa6f1c608698c387a8c (diff)
gentoo auto-resync : 10:11:2023 - 22:34:26
Diffstat (limited to 'net-dns/coredns')
-rw-r--r--net-dns/coredns/Manifest9
-rw-r--r--net-dns/coredns/coredns-1.11.1.ebuild123
-rw-r--r--net-dns/coredns/coredns-9999.ebuild119
-rw-r--r--net-dns/coredns/files/buildopts-gitcommit-makefile-1.11.1.patch29
-rw-r--r--net-dns/coredns/files/coredns.service4
-rw-r--r--net-dns/coredns/metadata.xml20
6 files changed, 296 insertions, 8 deletions
diff --git a/net-dns/coredns/Manifest b/net-dns/coredns/Manifest
index 8861872eab28..be3e20063040 100644
--- a/net-dns/coredns/Manifest
+++ b/net-dns/coredns/Manifest
@@ -1,10 +1,15 @@
AUX Corefile.example 129 BLAKE2B f82689761122e4fef2ec229d43fb32b6e917e480f5c669f26bd0dfda092f446744865576ab28564eca9474cd578f71f6d4c45d7145e1773e240afff1577a9103 SHA512 464322d42be12744514a62c47c2e97ff24884a265def98b18288a1203d357e7df1511d44d64aa4881e18210b4712d16d8f25a2a873a7549712059a68012c4cdc
+AUX buildopts-gitcommit-makefile-1.11.1.patch 902 BLAKE2B a8e8c0bada1f521589894b5712af3772b2dc9d59eaa3ed54eebb4f6e1a904a0da322501c09c5fe461f09a9ded7ac0747d26b7c79fdd23994a559102a55355b75 SHA512 d25dc863116f37c486030a70c7703318cc6aff3793add007959ceed771e433ec8e6000c5426cfc12fb636da3f4bcb849ba11605e16162ac4d2c84edea63f70c7
AUX coredns.confd 177 BLAKE2B 6354c6cd72850df7d381882d8648e711835dd3c082b442418210578b281af291ba02d2211ac2f99c05e1b80ae16ea4de936fcb18f178a79e774c65b3cec97208 SHA512 57c83e4b7f5f783bbdaae8300fa83a8707f2681b63f0ae6b562d3a9e9bac993b70330865d383239bf38949a6f1e092cac6e0d0b70409d747b745d06d257f7fb4
AUX coredns.initd 779 BLAKE2B 355a1b90856f596a10fa4c0ba294cf2d888ff9a5f7b0b71ef491cd29bfccd6b65a645839d581fce77cbb1bd07c9b6f6bd71b08d4034c9cc6b0bf92a25f2fde50 SHA512 a704fab0cab90a3709129552088f83820cf17b65ac5434d3e7f2017602f825145376a32126ef78139c349daef498bcd53031b92e96e948fb01ad53bb0f97a8bf
AUX coredns.logrotated 81 BLAKE2B 7fe70e32133a9470a60834dee5632151ed215e478a9de697dbca3ee553e5a8719bc941251c6a37723625b7c59f10f5050c79edb94ac8d4127561c12813ba6a27 SHA512 c697c08c3b1153ae224a1eeb3521f9ee594de4852bc6ef78d94dc7f6f680517659a653ab5c13ea03918deb79e6654ef11512ba4c90fe06ea4591fefbab876ece
-AUX coredns.service 452 BLAKE2B 835277ab1a76a6841d2f7f8cd7fa604351064d9ea88bcff2771f8526dd8e20f8b03604af234d1c7fade670f2b9c709b8567be7a0a06805ea539e7706ed103f2d SHA512 29bdeea1fe97f48a979581736115fd75d9fbcb544ca67064f2b07467549aff5c09760b0b172af812876094eb75d3352a075d68effb50be41b21f908dc774f4c8
+AUX coredns.service 516 BLAKE2B a28a1aa078abc4946c67a8d65114fee6a845af2e6338e052ea5fccf217dea7a61b962dc37306dc3250b7b71c498c45c6fadc48412831c9e18ca324201d4b8dda SHA512 53f865f29642ffc77e960cdfa82ca341d33ecb9555991ca0f9abcbe238f050e786519c414ea570f66731e27f770fdd02fece0fb2a64343f0c41c11ed208c47a6
AUX coredns.tmpfiles 42 BLAKE2B 06e6b3be85cc66f5eb126639496dc962cbb3e9b77ca59da1acc4749208212ac24bbc53cd694ce63c579528ca040443a5cb3886ea05baf5b0cceb3f46fe94ff20 SHA512 b6aaf9b399a5c25efbbb4f23d9a0c97af0749adea7a58ae83af8b8220a167778ac8debc0359c75d3ac8b904176ee870523c9101f22e8352b61b2012c9002bab4
DIST coredns-1.10.1-deps.tar.xz 230970760 BLAKE2B 79e9199256ddcb5c6728aa1cab62608177099d278a44bc5393148ed49139fa97ebc82fd0e749847bb04f34b409165c44082cbec502e807e0e44c58b4f1df5f6f SHA512 2c1a5d6ba3392444a25ca0488c8c0ebae4090b601276a17fdc01c64b70c22fa45b297c8784dbb7214865ceafe4b93bb166d3e84b170a5e1b21ff3811b59ab885
DIST coredns-1.10.1.tar.gz 632459 BLAKE2B ade57e2f7028cf4c3b69e08396a7cd41cde79c6f0b9b1edeb4c9e73204e9eab295d9b44dce437f337900ca6a622832c6f784f7088b2eed7ac6759e6959e587bd SHA512 6906ecf64b6274f4d3957faec6930ec3ed4de0bddd9e2d72ea2794f43186689ede1f440d7626c5ea66956fdec41e354242f99fa489f1f992b86fede5f580a328
+DIST coredns-1.11.1-deps.tar.xz 252844888 BLAKE2B c249a6d52965ac4a6b7e06343d5155e3bc6f0528c11556fda9eb111beec1b4a71ac1b7cc8c76d0c593fedddccf3d3808a0da8145555a804b0284557280bb8dab SHA512 0a22fa25cdbe5e8686612d411b59758ab604a3cf9a92a02eed7b5487506c25dee90c113dcb479fb9da199a31ead2c818ebe856f6f7182967ba13b9852d6e785a
+DIST coredns-1.11.1.tar.gz 647236 BLAKE2B 0f2c58608a6a13b57c7df45a8f750ef5b9b6da4be4e5b593cb992141dc6d0e238121789e4ca0b430a100963c3bf08c0257506c812da776ea47a164f83b4fd0cc SHA512 f8752811e9e7913311f47ae13f35c755ac86ea240572be1c1dabc1712b6c42380c60ac385fa9573c77d6fcf4c144df2bc00574f18e8d7b70da21ed8ae4fb87cd
EBUILD coredns-1.10.1.ebuild 2369 BLAKE2B fff6a9a01bdda4b46859b6382d4a0a6a9bb6aa89e0d39c2d83747b31b490a56d640952c82e43ef1e05ea25b1229d0ac293880ce1cbf1dbce4e79b7227118efc7 SHA512 f51761c89f13a80a1421ed7286fcd2a4744dafbef1129fa525bf603ae6d37a95bc4ed9274c7e86c6aecbb66063230252358d8a634582b7443f422858f0ae84a0
-MISC metadata.xml 783 BLAKE2B cf0d7a90c49810d0411c529a75de683c084dd6649a3b3095906e028e21fc4679491bbc8cd55117362bbf4a53befb9006fc14a5b1ce76b873070817029751482e SHA512 95183bd32f17ee75e6b285ac54e0f44359786f058157c95ce59aa8726c6509476ba6a7d049fe32aef43a681d9a9c7684aa5fef4fc46f722a82948318de0bb48b
+EBUILD coredns-1.11.1.ebuild 3093 BLAKE2B 8757fa5b04ac33e0c13d04364f9e5297f612cee03f921a3e3913bfbf4619992e7662a9dbb506448eddfb741aba6ff81dbdbf77d9a4f7834916ef98f00e3a5815 SHA512 186df02c8c41cf547bd85c7adec400fd372df1ec392668969c07e320815c1a1ffe043c52cd563923a3b851789639e8de1a4c4279b50770e6318478cd37073a49
+EBUILD coredns-9999.ebuild 3072 BLAKE2B c582e3318993aad0e51ae7f310db7425d1b98c7be3830e2450fe5aa3133fc220a3c8efcccabb86a8e8be0fb7dcd59abe99cf368adb2c1c2374cc3af21e282af5 SHA512 b9476241fce9b3198e88fca5800504e958abf47d6b970be505443c398a90d3794e2e9fac1df976f53157da88460b16df8eccf9e80b840c629286eef6015a51c5
+MISC metadata.xml 1159 BLAKE2B ce3b2da146c9fdfda5a8351e7d9c177452af73fda38289c9b5f70c2ca6eee7d0916a8c8f60068831fb7aa0517ec49a3d676e282c3e0ca84ba65f5a9c17f302c8 SHA512 82f754e8b279a94b0a584277c3a8e012f5240e326fd96e96a3be951aedc23134efc0271b4eea2e0c698ce9c4937c4e1361b39bcd5f413630caadcd425b368c29
diff --git a/net-dns/coredns/coredns-1.11.1.ebuild b/net-dns/coredns/coredns-1.11.1.ebuild
new file mode 100644
index 000000000000..59d3b5206848
--- /dev/null
+++ b/net-dns/coredns/coredns-1.11.1.ebuild
@@ -0,0 +1,123 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit fcaps go-module multiprocessing systemd tmpfiles toolchain-funcs
+
+DESCRIPTION="CoreDNS is a DNS server that chains plugins"
+HOMEPAGE="https://github.com/coredns/coredns"
+
+if [[ ${PV} == 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/coredns/coredns.git"
+else
+ SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ SRC_URI+=" https://dev.gentoo.org/~zmedico/dist/${P}-deps.tar.xz"
+ KEYWORDS="~amd64"
+fi
+
+# main
+LICENSE="Apache-2.0"
+# deps
+LICENSE+=" MIT BSD ISC MPL-2.0 BSD-2"
+
+SLOT="0"
+IUSE="test"
+# TODO: debug test failure with deps tarball
+RESTRICT="test"
+
+RDEPEND="acct-user/coredns
+ acct-group/coredns"
+
+FILECAPS=(
+ -m 755 'cap_net_bind_service=+ep' usr/bin/${PN}
+)
+
+PATCHES=(
+ "${FILESDIR}/buildopts-gitcommit-makefile-1.11.1.patch"
+)
+
+src_unpack() {
+ if [[ ${PV} == *9999* ]]; then
+ git-r3_src_unpack
+ go-module_live_vendor
+ else
+ go-module_src_unpack
+ fi
+}
+
+src_prepare() {
+ default
+ use test || sed -i -e 's|coredns: $(CHECKS)|coredns:|' Makefile
+}
+
+src_compile() {
+ # For non-live versions, prevent git operations which causes sandbox violations
+ # https://github.com/gentoo/gentoo/pull/33531#issuecomment-1786107493
+ [[ ${PV} != 9999* ]] && export GITCOMMIT=''
+
+ # Mimicking go-module.eclass's GOFLAGS
+ if use amd64 || use arm || use arm64 ||
+ ( use ppc64 && [[ $(tc-endian) == "little" ]] ) || use s390 || use x86; then
+ local buildmode="-buildmode=pie"
+ fi
+ export BUILDOPTS="-buildvcs=false -modcacherw -v -x -p=$(makeopts_jobs) ${buildmode}"
+
+ default
+}
+
+src_install() {
+ dobin "${PN}"
+ einstalldocs
+ doman man/*
+
+ newinitd "${FILESDIR}"/coredns.initd coredns
+ newconfd "${FILESDIR}"/coredns.confd coredns
+
+ insinto /etc/coredns/
+ newins "${FILESDIR}"/Corefile.example Corefile
+
+ insinto /etc/logrotate.d
+ newins "${FILESDIR}"/coredns.logrotated coredns
+
+ systemd_dounit "${FILESDIR}"/coredns.service
+ newtmpfiles "${FILESDIR}"/coredns.tmpfiles "${PN}.conf"
+}
+
+src_test() {
+ # eclass default '-x' makes tests output unreadable
+ export GOFLAGS="-v -mod=readonly"
+
+ local known_fail=(
+ "TestZoneExternalCNAMELookupWithProxy"
+ "TestMetricsSeveralBlocs"
+ "TestMetricsAvailable"
+ "TestMetricsAvailableAfterReload"
+ "TestMetricsAvailableAfterReloadAndFailedReload"
+ )
+ # concat as '|^Test1$|^Test2$|^Test3...$':
+ local known_fail_re="$(printf '|^%s$' "${known_fail[@]}")"
+ # drop '|' in the begining:
+ known_fail_re="${known_fail_re:1}"
+
+ local working_tests_re="$(
+ # get list of all test:
+ { GOFLAGS="-mod=readonly" go test -list . ./... ||
+ die "Can't get list of tests"; } |
+ # skip "no tests" messages as well as know failures:
+ grep -v -E " |${known_fail_re}" |
+ # format a regexp:
+ sed -z 's/\n/$|^/g'
+ )"
+ # drop '|^' in the end:
+ working_tests_re="^${working_tests_re::-2}"
+
+ go test -race -run "${working_tests_re}" ./... || die "Tests failed"
+ go test -race -run "${known_fail_re}" ./... || ewarn "Known test failure"
+}
+
+pkg_postinst() {
+ fcaps_pkg_postinst
+ tmpfiles_process ${PN}.conf
+}
diff --git a/net-dns/coredns/coredns-9999.ebuild b/net-dns/coredns/coredns-9999.ebuild
new file mode 100644
index 000000000000..52c5778f1173
--- /dev/null
+++ b/net-dns/coredns/coredns-9999.ebuild
@@ -0,0 +1,119 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit fcaps go-module multiprocessing systemd tmpfiles toolchain-funcs
+
+DESCRIPTION="CoreDNS is a DNS server that chains plugins"
+HOMEPAGE="https://github.com/coredns/coredns"
+
+if [[ ${PV} == 9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/coredns/coredns.git"
+else
+ SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+ SRC_URI+=" https://github.com/rahilarious/gentoo-distfiles/releases/download/${P}/deps.tar.xz -> ${P}-deps.tar.xz"
+ KEYWORDS="~amd64"
+fi
+
+# main
+LICENSE="Apache-2.0"
+# deps
+LICENSE+=" MIT BSD ISC MPL-2.0 BSD-2"
+
+SLOT="0"
+IUSE="test"
+# TODO: debug test failure with deps tarball
+RESTRICT="test"
+
+RDEPEND="acct-user/coredns
+ acct-group/coredns"
+
+FILECAPS=(
+ -m 755 'cap_net_bind_service=+ep' usr/bin/${PN}
+)
+
+src_unpack() {
+ if [[ ${PV} == *9999* ]]; then
+ git-r3_src_unpack
+ go-module_live_vendor
+ else
+ go-module_src_unpack
+ fi
+}
+
+src_prepare() {
+ default
+ use test || sed -i -e 's|coredns: $(CHECKS)|coredns:|' Makefile
+}
+
+src_compile() {
+ # For non-live versions, prevent git operations which causes sandbox violations
+ # https://github.com/gentoo/gentoo/pull/33531#issuecomment-1786107493
+ [[ ${PV} != 9999* ]] && export GITCOMMIT=''
+
+ # Mimicking go-module.eclass's GOFLAGS
+ if use amd64 || use arm || use arm64 ||
+ ( use ppc64 && [[ $(tc-endian) == "little" ]] ) || use s390 || use x86; then
+ local buildmode="-buildmode=pie"
+ fi
+ export BUILDOPTS="-buildvcs=false -modcacherw -v -x -p=$(makeopts_jobs) ${buildmode}"
+
+ default
+}
+
+src_install() {
+ dobin "${PN}"
+ einstalldocs
+ doman man/*
+
+ newinitd "${FILESDIR}"/coredns.initd coredns
+ newconfd "${FILESDIR}"/coredns.confd coredns
+
+ insinto /etc/coredns/
+ newins "${FILESDIR}"/Corefile.example Corefile
+
+ insinto /etc/logrotate.d
+ newins "${FILESDIR}"/coredns.logrotated coredns
+
+ systemd_dounit "${FILESDIR}"/coredns.service
+ newtmpfiles "${FILESDIR}"/coredns.tmpfiles "${PN}.conf"
+}
+
+src_test() {
+ # eclass default '-x' makes tests output unreadable
+ export GOFLAGS="-v -mod=readonly"
+
+ local known_fail=(
+ "TestZoneExternalCNAMELookupWithProxy"
+ "TestMetricsSeveralBlocs"
+ "TestMetricsAvailable"
+ "TestMetricsAvailableAfterReload"
+ "TestMetricsAvailableAfterReloadAndFailedReload"
+ )
+ # concat as '|^Test1$|^Test2$|^Test3...$':
+ local known_fail_re="$(printf '|^%s$' "${known_fail[@]}")"
+ # drop '|' in the begining:
+ known_fail_re="${known_fail_re:1}"
+
+ local working_tests_re="$(
+ # get list of all test:
+ { GOFLAGS="-mod=readonly" go test -list . ./... ||
+ die "Can't get list of tests"; } |
+ # skip "no tests" messages as well as know failures:
+ grep -v -E " |${known_fail_re}" |
+ # format a regexp:
+ sed -z 's/\n/$|^/g'
+ )"
+ # drop '|^' in the end:
+ working_tests_re="^${working_tests_re::-2}"
+
+ go test -race -run "${working_tests_re}" ./... || die "Tests failed"
+ go test -race -run "${known_fail_re}" ./... || ewarn "Known test failure"
+}
+
+pkg_postinst() {
+ fcaps_pkg_postinst
+ tmpfiles_process ${PN}.conf
+}
diff --git a/net-dns/coredns/files/buildopts-gitcommit-makefile-1.11.1.patch b/net-dns/coredns/files/buildopts-gitcommit-makefile-1.11.1.patch
new file mode 100644
index 000000000000..97dd658786e6
--- /dev/null
+++ b/net-dns/coredns/files/buildopts-gitcommit-makefile-1.11.1.patch
@@ -0,0 +1,29 @@
+# https://github.com/coredns/coredns/pull/6384
+From 81938bca2041c9dddc1171d56f609191313b8b9d Mon Sep 17 00:00:00 2001
+From: Rahil Bhimjiani <rahil3108@gmail.com>
+Date: Sun, 5 Nov 2023 21:53:05 +0530
+Subject: [PATCH] Makefile: allow to use custom GITCOMMIT & BUILDOPTS
+
+?= means If GITCOMMIT/BUILDOPTS is defined then use that otherwise fallback to default
+
+Signed-off-by: Rahil Bhimjiani <rahil3108@gmail.com>
+---
+ Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 43d03e207ba..10fca3da1a1 100644
+--- a/Makefile
++++ b/Makefile
+@@ -1,9 +1,9 @@
+ # Makefile for building CoreDNS
+-GITCOMMIT:=$(shell git describe --dirty --always)
++GITCOMMIT?=$(shell git describe --dirty --always)
+ BINARY:=coredns
+ SYSTEM:=
+ CHECKS:=check
+-BUILDOPTS:=-v
++BUILDOPTS?=-v
+ GOPATH?=$(HOME)/go
+ MAKEPWD:=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))
+ CGO_ENABLED?=0
diff --git a/net-dns/coredns/files/coredns.service b/net-dns/coredns/files/coredns.service
index eab9aede713e..fc2ec10c5c43 100644
--- a/net-dns/coredns/files/coredns.service
+++ b/net-dns/coredns/files/coredns.service
@@ -1,7 +1,9 @@
[Unit]
Description=CoreDNS DNS server
+Documentation=man:coredns(1)
Documentation=https://coredns.io
-After=network.target
+After=network-online.target
+Wants=network-online.target
[Service]
PermissionsStartOnly=true
diff --git a/net-dns/coredns/metadata.xml b/net-dns/coredns/metadata.xml
index 970332552b10..e8fcef2c53db 100644
--- a/net-dns/coredns/metadata.xml
+++ b/net-dns/coredns/metadata.xml
@@ -5,14 +5,24 @@
<email>zmedico@gentoo.org</email>
<name>Zac Medico</name>
</maintainer>
+ <maintainer type="person" proxied="yes">
+ <email>rahil3108@gmail.com</email>
+ <name>Rahil Bhimjiani</name>
+ </maintainer>
+ <maintainer type="project" proxied="proxy">
+ <email>proxy-maint@gentoo.org</email>
+ <name>Proxy Maintainers</name>
+ </maintainer>
<longdescription>
- CoreDNS is a DNS server/forwarder, written in Go, that chains plugins.
- It is fast and flexible. The key word here is flexible:
- with CoreDNS you are able to do what you want with your DNS data by utilizing plugins.
- CoreDNS can listen for DNS requests coming in over UDP/TCP (go'old DNS), TLS (RFC 7858),
- also called DoT, DNS over HTTP/2 - DoH - (RFC 8484) and gRPC (not a standard).
+ CoreDNS is a DNS server/forwarder, written in Go, that chains plugins.
+ It is fast and flexible. The key word here is flexible:
+ with CoreDNS you are able to do what you want with your DNS data by utilizing plugins.
+ CoreDNS can listen for DNS requests coming in over UDP/TCP (go'old DNS), TLS (RFC 7858),
+ also called DoT, DNS over HTTP/2 - DoH - (RFC 8484) and gRPC (not a standard).
</longdescription>
<upstream>
<remote-id type="github">coredns/coredns</remote-id>
+ <bugs-to>https://github.com/coredns/coredns/issues</bugs-to>
+ <doc>https://coredns.io/manual/toc/</doc>
</upstream>
</pkgmetadata>