mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-08-05 21:37:15 +02:00
testing/neo4j: add cypher-shell subpackage
This commit is contained in:
parent
ef2fc2236b
commit
3d7d60c0ea
@ -15,23 +15,34 @@ depends="
|
||||
java-zstd-jni
|
||||
openjdk11-jre-headless
|
||||
"
|
||||
_depends_shell="
|
||||
java-jna
|
||||
java-netty-transport-native
|
||||
java-jre-headless
|
||||
"
|
||||
makedepends="
|
||||
bash
|
||||
$_depends_shell
|
||||
openjdk11
|
||||
maven
|
||||
unzip
|
||||
zip
|
||||
"
|
||||
checkdepends="bash"
|
||||
install="$pkgname.pre-install"
|
||||
pkgusers="neo4j"
|
||||
pkggroups="neo4j"
|
||||
subpackages="$pkgname-doc $pkgname-openrc"
|
||||
subpackages="
|
||||
$pkgname-doc
|
||||
$pkgname-openrc
|
||||
cypher-shell:_shell:noarch
|
||||
"
|
||||
source="https://github.com/neo4j/neo4j/archive/refs/tags/$pkgver/neo4j-$pkgver.tar.gz
|
||||
system-jars.patch
|
||||
conf.patch
|
||||
wrapper.sh
|
||||
neo4j.initd
|
||||
neo4j.confd
|
||||
$pkgname.initd
|
||||
$pkgname.confd
|
||||
cypher-shell
|
||||
"
|
||||
# net: fetches packages from Maven repos
|
||||
# check: needs ulimit -n 40000
|
||||
@ -61,6 +72,11 @@ build() {
|
||||
|
||||
mkdir -p dist
|
||||
tar -C dist -xf packaging/standalone/target/neo4j-community-*-unix.tar.gz
|
||||
|
||||
cd dist/neo4j-community-*
|
||||
|
||||
# Remove jansi native binaries (they are actually not needed).
|
||||
zip -qd bin/tools/cypher-shell.jar 'org/fusesource/jansi/internal/native/*'
|
||||
}
|
||||
|
||||
check() {
|
||||
@ -85,6 +101,10 @@ package() {
|
||||
install -D -m755 "$srcdir"/neo4j.initd "$pkgdir"/etc/init.d/neo4j
|
||||
install -D -m644 "$srcdir"/neo4j.confd "$pkgdir"/etc/conf.d/neo4j
|
||||
|
||||
# cypher-shell
|
||||
install -D -m644 bin/tools/cypher-shell.jar -t "$pkgdir"/usr/share/cypher-shell/
|
||||
install -D -m755 "$srcdir"/cypher-shell -t "$pkgdir"/usr/bin/
|
||||
|
||||
cd "$pkgdir"
|
||||
|
||||
install -d -o neo4j -g neo4j -m750 \
|
||||
@ -111,6 +131,14 @@ package() {
|
||||
done
|
||||
}
|
||||
|
||||
_shell() {
|
||||
pkgdesc="Cypher Shell - CLI for Neo4j"
|
||||
depends="$_depends_shell"
|
||||
|
||||
amove usr/bin/cypher-shell
|
||||
amove usr/share/cypher-shell
|
||||
}
|
||||
|
||||
_jar_version() {
|
||||
unzip -p "$1" META-INF/MANIFEST.MF | sed -En 's/Implementation-Version: (\S+).*/\1/p'
|
||||
}
|
||||
@ -122,4 +150,5 @@ sha512sums="
|
||||
a1b6f509228dd9925420591803595c67653924ea592c38894f7d3d26e24b40bbc9b35e8b4e67611df9e06a7f0921b13e3f2f1bb54102049c3b1f9c6a2656939d wrapper.sh
|
||||
f61a76246039187dcc61bdfd7482e4928ae7b356571e56c86f7b7a243dced79c8d61f0c6ab807ca7f993a78640cda427316a9b274844c794b769b992ff897498 neo4j.initd
|
||||
8530390bb5292318f03b76d3afe23a3029971f90ce4b0e702d18913c01000c6df8644d6c7415ab6dde2d02f9a4af490234ce817aa2d6976554a971e1ff707d4f neo4j.confd
|
||||
45a3b4f9db522eca6dbc616b17005f7ec75a1168242f465dfd6d2475be3cba465573920d34e4fd192d5f0c838e049f4ea6d46d9a56193f4079a8850f4090dfeb cypher-shell
|
||||
"
|
||||
|
6
testing/neo4j/cypher-shell
Normal file
6
testing/neo4j/cypher-shell
Normal file
@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
|
||||
JAVA_CMD="java"
|
||||
[ "$JAVA_HOME" ] && JAVA_CMD="$JAVA_HOME/bin/java"
|
||||
|
||||
exec "$JAVA_CMD" $JAVA_OPTS -cp /usr/share/java/jna.jar -jar /usr/share/cypher-shell/cypher-shell.jar "$@"
|
Loading…
Reference in New Issue
Block a user