summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorml2020-08-09 11:11:21 +0200
committerml2020-08-09 11:11:21 +0200
commite67f5487d83563ebc08b4138fed12b55b5182cfa (patch)
tree9cb2b6a1f3c13365081e69b7b190508e10b13be9 /PKGBUILD
downloadaur-e67f5487d83563ebc08b4138fed12b55b5182cfa.tar.gz
newpkg: kubectl-doctor 0.3.0-1
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD33
1 files changed, 33 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..7f6cda18aef2
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,33 @@
+# Maintainer: ml <ml@visu.li>
+pkgname=kubectl-doctor
+pkgver=0.3.0
+pkgrel=1
+pkgdesc='kubectl cluster triage plugin for k8s'
+arch=('x86_64' 'aarch64')
+url='https://github.com/emirozer/kubectl-doctor'
+license=('Apache')
+depends=('glibc')
+makedepends=('go')
+groups=('kubectl-plugins')
+source=("$url/archive/$pkgver/$pkgname-$pkgver.tar.gz")
+sha256sums=('1d0faeba6875228bc9e77261e55cbc6c7b2ffaabf90c4c3f7fe96f8ea8e299bb')
+
+prepare() {
+ cd "$pkgname-$pkgver"
+ go mod download
+}
+
+build() {
+ cd "$pkgname-$pkgver"
+ export CGO_ENABLED=1
+ export CGO_LDFLAGS="$LDFLAGS"
+ export CGO_CFLAGS="$CFLAGS"
+ export CGO_CPPFLAGS="$CPPFLAGS"
+ export CGO_CXXFLAGS="$CXXFLAGS"
+ export GOFLAGS='-buildmode=pie -trimpath -modcacherw -mod=readonly'
+ go build ./cmd/kubectl-doctor.go
+}
+
+package() {
+ install -Dm755 "$pkgname-$pkgver/$pkgname" -t "$pkgdir/usr/bin"
+}