diff options
author | 2022-05-22 17:41:07 -0700 | |
---|---|---|
committer | 2022-05-22 17:41:07 -0700 | |
commit | c748f23439bd1572005fab064e66c45b84b782c7 (patch) | |
tree | a936a2071350b07d4c4f8b6bc601be58dd8b2848 /app-containers | |
parent | net-misc/dnsname-cni-plugin: move dnsname v1.3.0, v1.3.1, and v9999 to dnsnam... (diff) | |
download | guru-c748f23439bd1572005fab064e66c45b84b782c7.tar.gz guru-c748f23439bd1572005fab064e66c45b84b782c7.tar.bz2 guru-c748f23439bd1572005fab064e66c45b84b782c7.zip |
app-containers/dnsname-cni-plugin: move dnsname-cni-plugin to app-container
The commits moves dnsname-cni-plugin to app-container from net-misc.
Signed-off-by: Randall T. Vasquez <ran.dall@icloud.com>
Diffstat (limited to 'app-containers')
5 files changed, 229 insertions, 0 deletions
diff --git a/app-containers/dnsname-cni-plugin/Manifest b/app-containers/dnsname-cni-plugin/Manifest new file mode 100644 index 000000000..b3ea30966 --- /dev/null +++ b/app-containers/dnsname-cni-plugin/Manifest @@ -0,0 +1,4 @@ +DIST dnsname-cni-plugin-1.3.0-deps.tar.xz 21020340 BLAKE2B 59f1bf713d464193dea3ff0e02cf6b82d1d9edf882186fbdf53959c3f70b2fb5a6a73bfbdf4c910613f6253c9f7f1c1c19e87f8586ee59a3e501c96931171936 SHA512 53322b89eccd639e1bde14496542f335ff10bbea711ea395ab36807d2d204f811cb051a07120f54679e3d61da2e3271983a36724fa91db5d5e52c7d3cc736b59 +DIST dnsname-cni-plugin-1.3.0.tar.gz 2526598 BLAKE2B 0a17998c61c72e858d8f7a13d31c54e2b6e3495c61a2cbaaeadbade863361a468aaaf1c291fd073e77df3ff83f231d168208551143009400ad60a25f921f9bf2 SHA512 df48c4715582f098c41d45533163632ac1953621ce91fc78e88cc84e61d8a0a537e6da5aabab2be18cbddccd8e4c867670ae1fbc5ff7b6473bf7f4b464cb6ee2 +DIST dnsname-cni-plugin-1.3.1-deps.tar.xz 21051388 BLAKE2B 39393408677061355f04995d12df11bb53260f5cee5309f44d99719fa61d1ab29032a7cee931e4277098b5bb98d051587ac585c69b4a19633a79085106744d25 SHA512 4ea0249b7ba747cbe10162725abc56282ee3453213d9f590a53d2d8475c071c0ffabfa50b919bb119fff37a85d3d40d544e94d008fe9969100cac9c3d60039fe +DIST dnsname-cni-plugin-1.3.1.tar.gz 2526593 BLAKE2B 1fd7ced187ee25a6b31746ed7c73eba412f74c809adcf531aa9a03ed53e5c1b14f065dcc81eac28eff56d1c213583e931c861d31743abe164290867e84b1b95a SHA512 ebebbe62394b981e86cd21fa8b92639a6d67e007a18c576ffdbac8067084a4cffdc9d077213bf7c9ee1e2731c7d69e4d4c02465f2340556c8723b6e302238aad diff --git a/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-1.3.0.ebuild b/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-1.3.0.ebuild new file mode 100644 index 000000000..01ce66053 --- /dev/null +++ b/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-1.3.0.ebuild @@ -0,0 +1,72 @@ +# Copyright 2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +EGIT_COMMIT="dc59f285546a0b0d8b8f20033e1637ea82587840" +MY_PN=${PN//-cni-plugin} +MY_P=${MY_PN}-${PV} + +inherit flag-o-matic go-module + +DESCRIPTION="name resolution for containers" +HOMEPAGE="https://github.com/containers/dnsname" + +if [[ ${PV} == *9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/containers/dnsname.git" + RESTRICT="fetch mirror test" +else + SRC_URI="https://github.com/containers/dnsname/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + SRC_URI+=" https://github.com/ran-dall/portage-deps/raw/master/${P}-deps.tar.xz" + KEYWORDS="~amd64 ~arm64" + RESTRICT="mirror test" + S="${WORKDIR}"/${MY_P} +fi + +LICENSE="Apache-2.0" +SLOT="0" + +DEPEND=" + app-containers/podman + net-misc/cni-plugins + net-dns/dnsmasq +" +RDEPEND="${DEPEND}" + +src_unpack() { + default + if [[ ${PV} == *9999 ]]; then + git-r3_fetch + git-r3_checkout + pushd ${P}/plugins/meta/dnsname || die "location change for module building failed" + ego get + popd || die "location reset from module building failed" + fi +} + +src_prepare() { + default + rm LICENSE || die "removal of unneeded LICENSE failed" + rm CODE-OF-CONDUCT.md || die "removal of unneeded CODE-OF-CONDUCT.md failed" + rm RELEASE_NOTES.md || die "removal of unneeded RELEASE_NOTES.md failed" + rm OWNERS || die "a removal of an unneeded documentation file failed" +} + +src_compile() { + local git_commit=${EGIT_COMMIT} + # Disable LDFLAGS to avoid complation error; fixed in v1.3.1. + filter-ldflags ${LDFLAGS} + export -n GOCACHE GOPATH XDG_CACHE_HOME + GOBIN="${S}/bin" \ + emake all \ + GIT_BRANCH=master \ + GIT_BRANCH_CLEAN=master \ + COMMIT_NO="${git_commit}" \ + GIT_COMMIT="${git_commit}" +} + +src_install() { + exeinto /opt/cni/bin + doexe bin/* + dodoc README.md README_PODMAN.md SECURITY.md +} diff --git a/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-1.3.1.ebuild b/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-1.3.1.ebuild new file mode 100644 index 000000000..393eba1ff --- /dev/null +++ b/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-1.3.1.ebuild @@ -0,0 +1,70 @@ +# Copyright 2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +EGIT_COMMIT="18822f9a4fb35d1349eb256f4cd2bfd372474d84" +MY_PN=${PN//-cni-plugin} +MY_P=${MY_PN}-${PV} + +inherit go-module + +DESCRIPTION="name resolution for containers" +HOMEPAGE="https://github.com/containers/dnsname" + +if [[ ${PV} == *9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/containers/dnsname.git" + RESTRICT="fetch mirror test" +else + SRC_URI="https://github.com/containers/dnsname/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + SRC_URI+=" https://github.com/ran-dall/portage-deps/raw/master/${P}-deps.tar.xz" + KEYWORDS="~amd64 ~arm64" + RESTRICT="mirror test" + S="${WORKDIR}"/${MY_P} +fi + +LICENSE="Apache-2.0" +SLOT="0" + +DEPEND=" + app-containers/podman + net-misc/cni-plugins + net-dns/dnsmasq +" +RDEPEND="${DEPEND}" + +src_unpack() { + default + if [[ ${PV} == *9999 ]]; then + git-r3_fetch + git-r3_checkout + pushd ${MY_P}/plugins/meta/dnsname || die "location change for module building failed" + ego get + popd || die "location reset from module building failed" + fi +} + +src_prepare() { + default + rm LICENSE || die "removal of unneeded LICENSE failed" + rm CODE-OF-CONDUCT.md || die "removal of unneeded CODE-OF-CONDUCT.md failed" + rm RELEASE_NOTES.md || die "removal of unneeded RELEASE_NOTES.md failed" + rm OWNERS || die "a removal of an unneeded documentation file failed" +} + +src_compile() { + local git_commit=${EGIT_COMMIT} + export -n GOCACHE GOPATH XDG_CACHE_HOME + GOBIN="${S}/bin" \ + emake all \ + GIT_BRANCH=master \ + GIT_BRANCH_CLEAN=master \ + COMMIT_NO="${git_commit}" \ + GIT_COMMIT="${git_commit}" +} + +src_install() { + exeinto /opt/cni/bin + doexe bin/* + dodoc README.md README_PODMAN.md SECURITY.md +} diff --git a/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-9999.ebuild b/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-9999.ebuild new file mode 100644 index 000000000..ef5548ff1 --- /dev/null +++ b/app-containers/dnsname-cni-plugin/dnsname-cni-plugin-9999.ebuild @@ -0,0 +1,69 @@ +# Copyright 2022 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +MY_PN=${PN//-cni-plugin} +MY_P=${MY_PN}-${PV} + +inherit go-module + +DESCRIPTION="name resolution for containers" +HOMEPAGE="https://github.com/containers/dnsname" + +if [[ ${PV} == *9999 ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/containers/dnsname.git" + RESTRICT="fetch mirror test" +else + SRC_URI="https://github.com/containers/dnsname/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz" + SRC_URI+=" ${P}-deps.tar.xz" + KEYWORDS="~amd64 ~arm64" + RESTRICT="mirror test" + S="${WORKDIR}"/${MY_P} +fi + +LICENSE="Apache-2.0" +SLOT="0" + +DEPEND=" + app-containers/podman + net-misc/cni-plugins + net-dns/dnsmasq +" +RDEPEND="${DEPEND}" + +src_unpack() { + default + if [[ ${PV} == *9999 ]]; then + git-r3_fetch + git-r3_checkout + pushd ${P}/plugins/meta/dnsname || die "location change for module building failed" + ego get + popd || die "location reset from module building failed" + fi +} + +src_prepare() { + default + rm LICENSE || die "removal of unneeded LICENSE failed" + rm CODE-OF-CONDUCT.md || die "removal of unneeded CODE-OF-CONDUCT.md failed" + rm RELEASE_NOTES.md || die "removal of unneeded RELEASE_NOTES.md failed" + rm OWNERS || die "a removal of an unneeded documentation file failed" +} + +src_compile() { + local git_commit=${EGIT_COMMIT} + export -n GOCACHE GOPATH XDG_CACHE_HOME + GOBIN="${S}/bin" \ + emake all \ + GIT_BRANCH=master \ + GIT_BRANCH_CLEAN=master \ + COMMIT_NO="${git_commit}" \ + GIT_COMMIT="${git_commit}" +} + +src_install() { + exeinto /opt/cni/bin + doexe bin/* + dodoc README.md README_PODMAN.md SECURITY.md +} diff --git a/app-containers/dnsname-cni-plugin/metadata.xml b/app-containers/dnsname-cni-plugin/metadata.xml new file mode 100644 index 000000000..5e4235484 --- /dev/null +++ b/app-containers/dnsname-cni-plugin/metadata.xml @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>ran.dall@icloud.com</email> + <name>Randall Vasquez</name> + </maintainer> + <longdescription lang="en"> + This plugin sets up the use of dnsmasq on a given CNI network so that Pods can resolve each other by name. When configured, the pod and its IP address are added to a network specific hosts file that dnsmasq reads in. + </longdescription> + <upstream> + <remote-id type="github">containers/dnsname</remote-id> + </upstream> +</pkgmetadata> |