mirror of
https://github.com/bitnami/containers.git
synced 2026-03-14 06:48:11 +08:00
[bitnami/blackbox-exporter] Add VIB tests (#30035)
* [bitnami/blackbox-exporter] Add VIB tests Signed-off-by: Miguel Ruiz <miruiz@vmware.com> * Add triggers Signed-off-by: Miguel Ruiz <miruiz@vmware.com> * Add --preserve-status and increase timeout Signed-off-by: Miguel Ruiz <miruiz@vmware.com> * Remove help test Signed-off-by: Miguel Ruiz <miruiz@vmware.com> * Remove trigger Signed-off-by: Miguel Ruiz <miruiz@vmware.com> --------- Signed-off-by: Miguel Ruiz <miruiz@vmware.com>
This commit is contained in:
9
.vib/blackbox-exporter/goss/blackbox-exporter.yaml
Normal file
9
.vib/blackbox-exporter/goss/blackbox-exporter.yaml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
command:
|
||||||
|
check-blackbox-exporter-run:
|
||||||
|
exec: cd /opt/bitnami/blackbox-exporter && timeout --preserve-status 5 blackbox_exporter
|
||||||
|
timeout: 8000
|
||||||
|
exit-status: 0
|
||||||
|
stderr:
|
||||||
|
- Starting blackbox_exporter
|
||||||
|
- Loaded config file
|
||||||
|
- Listening on
|
||||||
11
.vib/blackbox-exporter/goss/goss.yaml
Normal file
11
.vib/blackbox-exporter/goss/goss.yaml
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
gossfile:
|
||||||
|
# Goss tests exclusive to the current container
|
||||||
|
../../blackbox-exporter/goss/blackbox-exporter.yaml: {}
|
||||||
|
# Load scripts from .vib/common/goss/templates
|
||||||
|
../../common/goss/templates/check-app-version.yaml: {}
|
||||||
|
../../common/goss/templates/check-binaries.yaml: {}
|
||||||
|
../../common/goss/templates/check-broken-symlinks.yaml: {}
|
||||||
|
../../common/goss/templates/check-ca-certs.yaml: {}
|
||||||
|
../../common/goss/templates/check-linked-libraries.yaml: {}
|
||||||
|
../../common/goss/templates/check-sed-in-place.yaml: {}
|
||||||
|
../../common/goss/templates/check-spdx.yaml: {}
|
||||||
6
.vib/blackbox-exporter/goss/vars.yaml
Normal file
6
.vib/blackbox-exporter/goss/vars.yaml
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
binaries:
|
||||||
|
- blackbox_exporter
|
||||||
|
root_dir: /opt/bitnami
|
||||||
|
version:
|
||||||
|
bin_name: blackbox_exporter
|
||||||
|
flag: --version
|
||||||
@@ -3,7 +3,8 @@
|
|||||||
"resources": {
|
"resources": {
|
||||||
"url": "{VIB_ENV_CONTAINER_URL}",
|
"url": "{VIB_ENV_CONTAINER_URL}",
|
||||||
"path": "{VIB_ENV_PATH}"
|
"path": "{VIB_ENV_PATH}"
|
||||||
}
|
},
|
||||||
|
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
|
||||||
},
|
},
|
||||||
"phases": {
|
"phases": {
|
||||||
"package": {
|
"package": {
|
||||||
@@ -33,6 +34,21 @@
|
|||||||
},
|
},
|
||||||
"verify": {
|
"verify": {
|
||||||
"actions": [
|
"actions": [
|
||||||
|
{
|
||||||
|
"action_id": "goss",
|
||||||
|
"params": {
|
||||||
|
"resources": {
|
||||||
|
"path": "/.vib"
|
||||||
|
},
|
||||||
|
"tests_file": "blackbox-exporter/goss/goss.yaml",
|
||||||
|
"vars_file": "blackbox-exporter/goss/vars.yaml",
|
||||||
|
"remote": {
|
||||||
|
"pod": {
|
||||||
|
"workload": "deploy-blackbox-exporter"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"action_id": "trivy",
|
"action_id": "trivy",
|
||||||
"params": {
|
"params": {
|
||||||
@@ -77,9 +93,9 @@
|
|||||||
"url": "{VIB_ENV_PACKAGES_JSON_URL}",
|
"url": "{VIB_ENV_PACKAGES_JSON_URL}",
|
||||||
"path": "/{VIB_ENV_PATH}",
|
"path": "/{VIB_ENV_PATH}",
|
||||||
"authn": {
|
"authn": {
|
||||||
"header": "Authorization",
|
"header": "Authorization",
|
||||||
"token": "Bearer {VIB_ENV_GITHUB_TOKEN}"
|
"token": "Bearer {VIB_ENV_GITHUB_TOKEN}"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,7 +3,8 @@
|
|||||||
"resources": {
|
"resources": {
|
||||||
"url": "{SHA_ARCHIVE}",
|
"url": "{SHA_ARCHIVE}",
|
||||||
"path": "{VIB_ENV_PATH}"
|
"path": "{VIB_ENV_PATH}"
|
||||||
}
|
},
|
||||||
|
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
|
||||||
},
|
},
|
||||||
"phases": {
|
"phases": {
|
||||||
"package": {
|
"package": {
|
||||||
@@ -29,6 +30,21 @@
|
|||||||
},
|
},
|
||||||
"verify": {
|
"verify": {
|
||||||
"actions": [
|
"actions": [
|
||||||
|
{
|
||||||
|
"action_id": "goss",
|
||||||
|
"params": {
|
||||||
|
"resources": {
|
||||||
|
"path": "/.vib"
|
||||||
|
},
|
||||||
|
"tests_file": "blackbox-exporter/goss/goss.yaml",
|
||||||
|
"vars_file": "blackbox-exporter/goss/vars.yaml",
|
||||||
|
"remote": {
|
||||||
|
"pod": {
|
||||||
|
"workload": "deploy-blackbox-exporter"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"action_id": "trivy",
|
"action_id": "trivy",
|
||||||
"params": {
|
"params": {
|
||||||
|
|||||||
Reference in New Issue
Block a user