[bitnami/logstash] Add VIB tests (#33411)

Signed-off-by: Marcos Bjoerkelund <marcosbd@vmware.com>
This commit is contained in:
Marcos Bjoerkelund
2023-05-25 12:07:02 +02:00
committed by GitHub
parent 5fdad83358
commit 8002e6fda1
5 changed files with 89 additions and 2 deletions
+13
View File
@@ -0,0 +1,13 @@
gossfile:
# Goss tests exclusive to the current container
../../logstash/goss/logstash.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-directories.yaml: {}
../../common/goss/templates/check-files.yaml: {}
../../common/goss/templates/check-linked-libraries.yaml: {}
../../common/goss/templates/check-sed-in-place.yaml: {}
../../common/goss/templates/check-spdx.yaml: {}
+19
View File
@@ -0,0 +1,19 @@
file:
/opt/bitnami/logstash/jdk:
exists: false
/opt/bitnami/logstash/config/logstash.yml:
exists: true
filetype: file
contains:
- "path.data: /bitnami/logstash/data"
/opt/bitnami/logstash/config/log4j2.properties:
exists: true
filetype: file
contains:
- "Console"
group:
logstash:
exists: true
user:
logstash:
exists: true
+23
View File
@@ -0,0 +1,23 @@
binaries:
- java
- logstash
- logstash-plugin
- yq
directories:
- mode: "0775"
paths:
- /bitnami/logstash
- /bitnami/logstash/config
- /bitnami/logstash/data
- /bitnami/logstash/pipeline
- /opt/bitnami/logstash/config
- /opt/bitnami/logstash/pipeline
- /opt/bitnami/logstash/vendor/bundle/jruby
files:
- paths:
- /opt/bitnami/logstash/Gemfile
- /opt/bitnami/logstash/Gemfile.lock
root_dir: /opt/bitnami
version:
bin_name: logstash
flag: --version
+17 -1
View File
@@ -3,7 +3,8 @@
"resources": {
"url": "{VIB_ENV_CONTAINER_URL}",
"path": "{VIB_ENV_PATH}"
}
},
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
},
"phases": {
"package": {
@@ -33,6 +34,21 @@
},
"verify": {
"actions": [
{
"action_id": "goss",
"params": {
"resources": {
"path": "/.vib"
},
"tests_file": "logstash/goss/goss.yaml",
"vars_file": "logstash/goss/vars.yaml",
"remote": {
"pod": {
"workload": "deploy-logstash"
}
}
}
},
{
"action_id": "trivy",
"params": {
+17 -1
View File
@@ -3,7 +3,8 @@
"resources": {
"url": "{SHA_ARCHIVE}",
"path": "{VIB_ENV_PATH}"
}
},
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
},
"phases": {
"package": {
@@ -29,6 +30,21 @@
},
"verify": {
"actions": [
{
"action_id": "goss",
"params": {
"resources": {
"path": "/.vib"
},
"tests_file": "logstash/goss/goss.yaml",
"vars_file": "logstash/goss/vars.yaml",
"remote": {
"pod": {
"workload": "deploy-logstash"
}
}
}
},
{
"action_id": "trivy",
"params": {