summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7a96676de5e4d448e5b0f577ee678561ef0616c6 (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
32
33
34
35
36
37
38
39
40
# Maintainer: grainrigi <naonaokiryu2 at gmail.com>

pkgname=cri-dockerd-git
pkgver=0.2.6
pkgrel=1
pkgdesc='A CRI implementation on top of Docker'
url='https://github.com/mirantis/cri-dockerd'
arch=('x86_64' 'armv7l' 'armv7h' 'aarch64')
license=(Apache)
makedepends=('go')
depends=('docker')
provides=('cri-dockerd')
_srcname=cri-dockerd
source=(
  'git+https://github.com/mirantis/cri-dockerd.git'
)
sha256sums=('SKIP')

pkgver() {
  cd $_srcname

  (git describe --abbrev=0 --tags | sed -e 's/v//') || echo $(cat VERSION)-$(git log -1 --pretty='%h')
}

build() {
  cd $_srcname

  mkdir -p bin
  echo 'Building...'
  go build -o bin/cri-dockerd
}

package() {
  cd $_srcname

  mkdir -p ${pkgdir}/usr/bin
  install -o root -g root -m 0755 bin/cri-dockerd ${pkgdir}/usr/bin/cri-dockerd
  mkdir -p ${pkgdir}/usr/lib/systemd/system
  cp -a packaging/systemd/* ${pkgdir}/usr/lib/systemd/system
}