blob: c0ef3c0812a81e41aa0b0b8424f45ccefd62b3e7 (
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
41
42
43
44
45
46
47
48
49
50
51
|
# Contributor: Francesco Colista <fcolista@alpinelinux.org>
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=etcd
pkgver=3.2.1
pkgrel=0
pkgdesc="A highly-available key value store for shared configuration and service discovery"
url="https://github.com/coreos/etcd"
arch="x86_64"
license="ASL 2.0"
makedepends="go bash"
options="!strip"
install="$pkgname.pre-install"
pkgusers="$pkgname"
pkggroups="$pkgname"
subpackages="$pkgname-doc $pkgname-ctl"
source="$pkgname-$pkgver.tar.gz::https://github.com/coreos/etcd/archive/v$pkgver.tar.gz
$pkgname.confd
$pkgname.initd"
builddir="$srcdir"/$pkgname-$pkgver
prepare() {
default_prepare
export GOPATH="$(pwd)/_gopath"
_coreos="${GOPATH}/src/github.com/coreos"
mkdir -vp ${_coreos}
ln -vsf ${srcdir}/${pkgname}-${pkgver} ${_coreos}/${pkgname}
}
build() {
cd "$builddir"
bash -x ./build
}
package() {
cd "$builddir"
mkdir -p "$pkgdir"/var/lib/$pkgname
chown -R $pkgusers:$pkggroups "$pkgdir"/var/lib/$pkgname
install -Dm755 bin/etcd "$pkgdir"/usr/bin/etcd
install -Dm755 $srcdir/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname
install -Dm755 $srcdir/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}
ctl() {
pkgdesc="A command-line client for etcd"
install -Dm755 "$builddir"/bin/etcdctl "$subpkgdir"/usr/bin/etcdctl
}
sha512sums="cf2f6e1633b43739edae74daaf2550c665b6fed0c94bac57636e3f02f9d54f467d674a70972649443ae9545abc0f3ba11675a478293f678812f4fe722d8c0964 etcd-3.2.1.tar.gz
440c9f23decb318c565a79d376b107dbd2333e72d5d812ec1460732543348737468b3e66e82e06a1afa0f09760c1eb066804a668a24e92a23977758727e049d2 etcd.confd
cee78d665c6449aceed2e12e13a461e614b7c71a4e4800c967bdfff0175e58aad1f8b0b186b8fa49ceffe315e5e68eccf24b8f3a3e3f805df8850f7e81b4ad12 etcd.initd"
|