summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManuel Rüger <mrueg@gentoo.org>2018-02-12 13:39:29 +0100
committerManuel Rüger <mrueg@gentoo.org>2018-02-12 13:41:52 +0100
commit37726ffc77bb6dd239d370a08ed1021082fc68ec (patch)
tree343a48ed1eb2ae80705917ebe885a3b0ea2463a0 /sys-cluster/kubectl/kubectl-1.9.3.ebuild
parentkde-frameworks: Drop KDE Frameworks 5.42.0 (diff)
downloadgentoo-37726ffc.tar.gz
gentoo-37726ffc.tar.bz2
gentoo-37726ffc.zip
sys-cluster/kubectl: Version bump to 1.9.3
Package-Manager: Portage-2.3.24, Repoman-2.3.6
Diffstat (limited to 'sys-cluster/kubectl/kubectl-1.9.3.ebuild')
-rw-r--r--sys-cluster/kubectl/kubectl-1.9.3.ebuild46
1 files changed, 46 insertions, 0 deletions
diff --git a/sys-cluster/kubectl/kubectl-1.9.3.ebuild b/sys-cluster/kubectl/kubectl-1.9.3.ebuild
new file mode 100644
index 000000000000..14674478c43c
--- /dev/null
+++ b/sys-cluster/kubectl/kubectl-1.9.3.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+inherit golang-build golang-vcs-snapshot bash-completion-r1
+
+EGO_PN="k8s.io/kubernetes"
+ARCHIVE_URI="https://github.com/kubernetes/kubernetes/archive/v${PV}.tar.gz -> kubernetes-${PV}.tar.gz"
+KEYWORDS="~amd64"
+
+DESCRIPTION="CLI to run commands against Kubernetes clusters"
+HOMEPAGE="https://github.com/kubernetes/kubernetes https://kubernetes.io"
+SRC_URI="${ARCHIVE_URI}"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE=""
+
+DEPEND="dev-go/go-bindata"
+
+RESTRICT="test"
+
+src_prepare() {
+ default
+ sed -i -e "/vendor\/github.com\/jteeuwen\/go-bindata\/go-bindata/d" src/${EGO_PN}/hack/lib/golang.sh || die
+ sed -i -e "/export PATH/d" src/${EGO_PN}/hack/generate-bindata.sh || die
+}
+
+src_compile() {
+ LDFLAGS="" GOPATH="${WORKDIR}/${P}" emake -j1 -C src/${EGO_PN} WHAT=cmd/${PN} GOFLAGS=-v
+ pushd src/${EGO_PN} || die
+ _output/bin/${PN} completion bash > ${PN}.bash || die
+ _output/bin/${PN} completion zsh > ${PN}.zsh || die
+ popd || die
+}
+
+src_install() {
+ pushd src/${EGO_PN} || die
+ dobin _output/bin/${PN}
+
+ newbashcomp ${PN}.bash ${PN}
+ insinto /usr/share/zsh/site-functions
+ newins ${PN}.zsh _${PN}
+
+ popd || die
+}