Add Alpine package runtime tests
This commit is contained in:
@@ -12,6 +12,8 @@ Optional package-local hooks:
|
||||
- `scripts/test-install.sh` validates README-style installation instructions.
|
||||
- `scripts/update-generated-sources.sh` refreshes generated files that are
|
||||
listed in `source=`.
|
||||
- `scripts/runtime-test.sh` validates an installed package in the shared Docker
|
||||
runtime test.
|
||||
|
||||
Repo-level tasks discover packages from `packaging/alpine/local/*/APKBUILD`.
|
||||
Limit a task to one or more packages with:
|
||||
@@ -20,6 +22,7 @@ Limit a task to one or more packages with:
|
||||
ALPINE_PACKAGE=<pkgname> mise run apk:build
|
||||
ALPINE_PACKAGES="<pkg-a> <pkg-b>" mise run apk:build-all
|
||||
ALPINE_PACKAGE=<pkgname> mise run apk:test-install
|
||||
ALPINE_PACKAGE=<pkgname> mise run apk:runtime-test
|
||||
```
|
||||
|
||||
For compiled software, put normal Alpine build logic in `build()`, `check()`,
|
||||
|
||||
@@ -0,0 +1,23 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
apk add greptimedb \
|
||||
greptimedb-datanode-openrc \
|
||||
greptimedb-docs \
|
||||
greptimedb-flownode-openrc \
|
||||
greptimedb-frontend-openrc \
|
||||
greptimedb-metasrv-openrc \
|
||||
greptimedb-standalone-openrc
|
||||
|
||||
test -x /usr/bin/greptime
|
||||
test -d /etc/greptimedb
|
||||
test -f /etc/greptimedb/standalone.toml
|
||||
test -f /etc/conf.d/greptimedb.standalone
|
||||
test -f /etc/init.d/greptimedb.standalone
|
||||
test -f /usr/share/doc/greptimedb/config/config.md
|
||||
test -f /usr/share/doc/greptimedb/config/standalone.example.toml
|
||||
|
||||
greptime --version
|
||||
|
||||
rc-update add greptimedb.standalone default || true
|
||||
test -L /etc/runlevels/default/greptimedb.standalone
|
||||
@@ -0,0 +1,37 @@
|
||||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
apk add seaweedfs \
|
||||
seaweedfs-doc \
|
||||
bash-completion \
|
||||
seaweedfs-master-openrc \
|
||||
seaweedfs-volume-openrc \
|
||||
seaweedfs-filer-openrc
|
||||
|
||||
test -x /usr/bin/weed
|
||||
test -d /etc/seaweedfs
|
||||
test -f /etc/seaweedfs/master.toml
|
||||
test -f /etc/seaweedfs/filer.toml
|
||||
test -f /etc/conf.d/seaweedfs.master
|
||||
test -f /etc/conf.d/seaweedfs.volume
|
||||
test -f /etc/conf.d/seaweedfs.filer
|
||||
test -f /etc/init.d/seaweedfs.master
|
||||
test -f /etc/init.d/seaweedfs.volume
|
||||
test -f /etc/init.d/seaweedfs.filer
|
||||
test -d /usr/share/doc/seaweedfs/examples
|
||||
test -f /usr/share/doc/seaweedfs/examples/master.toml
|
||||
test -f /usr/share/bash-completion/completions/weed
|
||||
|
||||
weed version
|
||||
|
||||
rc-update add seaweedfs.master default || true
|
||||
rc-update add seaweedfs.volume default || true
|
||||
rc-update add seaweedfs.filer default || true
|
||||
|
||||
rc-service seaweedfs.master start
|
||||
rc-service seaweedfs.volume start
|
||||
rc-service seaweedfs.filer start
|
||||
|
||||
rc-service seaweedfs.master status
|
||||
rc-service seaweedfs.volume status
|
||||
rc-service seaweedfs.filer status
|
||||
Reference in New Issue
Block a user