aboutsummaryrefslogtreecommitdiffstats
path: root/testing/kibana/APKBUILD
blob: 801742ec52f5728525c773565019b89821861f04 (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
52
53
54
55
56
57
58
# Contributor: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=kibana
pkgver=6.4.0
pkgrel=0
pkgdesc="Visualize Elasticsearch data and navigate the Elastic Stack"
url="https://www.elastic.co/products/kibana"
arch="x86_64"
license="Apache-2.0"
depends="nodejs"
install="$pkgname.pre-install"
subpackages="$pkgname-doc"
pkgusers="kibana"
pkggroups="kibana"
options="!check" # no test suite
source="https://artifacts.elastic.co/downloads/kibana/kibana-oss-$pkgver-linux-x86_64.tar.gz
	kibana.initd
	default_config.patch
	"
builddir="$srcdir"/$pkgname-$pkgver-linux-x86_64

build() {
	return 0
}

package() {
	cd "$builddir"
	install -m755 -d \
		"$pkgdir"/usr/share/webapps/$pkgname \
		"$pkgdir"/var/lib/$pkgname \
		"$pkgdir"/usr/share/doc/$pkgname

	# move config into /etc
	install -m755 -d "$pkgdir"/etc/$pkgname
	install -m644 -o $pkgusers -g $pkggroups config/kibana.yml "$pkgdir"/etc/$pkgname/kibana.yml
	rm config/kibana.yml && rmdir config

	# move data into /var
	install -m755 -o $pkgusers -g $pkggroups -d "$pkgdir"/var/lib/$pkgname/data
	rmdir data

	# remove ELF compiled against GLIBC
	rm node_modules/clipboardy/fallbacks/linux/xsel

	# move docs into subpkg
	mv *.txt "$pkgdir"/usr/share/doc/$pkgname

	# use system nodejs
	rm -rf node

	# everything else in webapps
	mv * "$pkgdir"/usr/share/webapps/$pkgname

	install -m755 -D "$srcdir"/$pkgname.initd $pkgdir/etc/init.d/$pkgname
}

sha512sums="eec78bb1935fdc126f7c69ea08c0997abc74f435f5ca24aa6fa370ad201dd1ebe9ab1d177f64ec66652a3c9c0dd3f13a8fa7866697d3f201f8bc124c051ebeba  kibana-oss-6.4.0-linux-x86_64.tar.gz
a6988b51ad758bce6c31aa90b905f833c7b641dec6b63a9da928c328b3da42a69bb855ecdbd22c15e035a20c6f28f90ddd88d85c6890acd58bef7608be2c25e8  kibana.initd
fae5536d02f6bb90d2e5930532e41b8327790eb83e412028b25eb0c7bd44d8fa38edd66fa9f4017d86819baba929e56dbc49bdb1dcbdea16f3447daa457514f4  default_config.patch"