summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: ffb2b77562ae1669c2ce34e64bb4a86a19ad0708 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Maintainer: Ivan Shapovalov <intelfx@intelfx.name>
# Contributor: ProFfeSsoRr <evvsoft at gmail dot com>

pkgname=crictl
pkgver=1.19.0
pkgrel=1
pkgdesc="CLI tool for Kubelet Container Runtime Interface (CRI)"
arch=(x86_64)
url="https://github.com/kubernetes-incubator/cri-tools/blob/master/docs/crictl.md"
license=('Apache')
makedepends=('git' 'go')
source=("git+https://github.com/kubernetes-sigs/cri-tools#tag=v${pkgver}"
        "crictl.yaml")
sha256sums=('SKIP'
            'd2725490e1fb2e6f565605f09871c1440371b85e04de5d70bbac05954d827f72')
backup=(etc/crictl.yaml)

build() {
  cd cri-tools
  make crictl
}

package() {
  cd cri-tools
  install -Dm755 _output/crictl "$pkgdir/usr/bin/crictl"
  install -Dm644 "$srcdir/crictl.yaml" "$pkgdir/etc/crictl.yaml"

  "$pkgdir/usr/bin/crictl" completion bash | install -Dm644 /dev/stdin "$pkgdir/usr/share/bash-completion/completions/crictl"
  "$pkgdir/usr/bin/crictl" completion zsh | install -Dm644 /dev/stdin "$pkgdir/usr/share/zsh/site-functions/_crictl"
}