[bitnami/dotnet] Add VIB tests (#24141)
* [bitnami/dotnet] Add VIB tests Signed-off-by: FraPazGal <fdepaz@vmware.com> * Remove VIB trigger Signed-off-by: FraPazGal <fdepaz@vmware.com> --------- Signed-off-by: FraPazGal <fdepaz@vmware.com>
This commit is contained in:
parent
22d7069bce
commit
6a837d7064
|
|
@ -0,0 +1,17 @@
|
|||
command:
|
||||
check-bin-caps:
|
||||
exec: getcap {{ .Vars.root_dir }}/dotnet/bin/dotnet
|
||||
stdout:
|
||||
- {{ .Vars.binary.capabilities }}
|
||||
exit-status: 0
|
||||
check-installed-runtimes:
|
||||
exec: dotnet --list-runtimes
|
||||
stdout:
|
||||
- NETCore.App {{ .Env.APP_VERSION }}
|
||||
exit-status: 0
|
||||
file:
|
||||
# Checks the postunpack phase properly creates the lib's symlink
|
||||
/lib64/libz.so:
|
||||
exists: true
|
||||
filetype: symlink
|
||||
linked-to: /usr/lib/libz.so.1
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
gossfile:
|
||||
# Goss tests exclusive to the current container
|
||||
../../dotnet/goss/dotnet.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-linked-libraries.yaml: {}
|
||||
../../common/goss/templates/check-sed-in-place.yaml: {}
|
||||
|
|
@ -0,0 +1,15 @@
|
|||
binaries:
|
||||
- dotnet
|
||||
directories:
|
||||
- paths:
|
||||
- /app
|
||||
mode: "0775"
|
||||
- paths:
|
||||
- /opt/bitnami/dotnet/bin/host
|
||||
- /opt/bitnami/dotnet/bin/shared
|
||||
root_dir: /opt/bitnami
|
||||
version:
|
||||
bin_name: dotnet
|
||||
flag: --info
|
||||
binary:
|
||||
capabilities: cap_net_bind_service=eip
|
||||
|
|
@ -3,11 +3,25 @@
|
|||
"resources": {
|
||||
"url": "{VIB_ENV_CONTAINER_URL}",
|
||||
"path": "{VIB_ENV_PATH}"
|
||||
}
|
||||
},
|
||||
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
|
||||
},
|
||||
"phases": {
|
||||
"package": {
|
||||
"actions": [
|
||||
{
|
||||
"action_id": "goss",
|
||||
"params": {
|
||||
"resources": {
|
||||
"path": "/.vib"
|
||||
},
|
||||
"tests_file": "dotnet/goss/goss.yaml",
|
||||
"vars_file": "dotnet/goss/vars.yaml",
|
||||
"remote": {
|
||||
"workload": "deploy-dotnet"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action_id": "container-image-package",
|
||||
"params": {
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
"resources": {
|
||||
"url": "{SHA_ARCHIVE}",
|
||||
"path": "{VIB_ENV_PATH}"
|
||||
}
|
||||
},
|
||||
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
|
||||
},
|
||||
"phases": {
|
||||
"package": {
|
||||
|
|
@ -29,6 +30,19 @@
|
|||
},
|
||||
"verify": {
|
||||
"actions": [
|
||||
{
|
||||
"action_id": "goss",
|
||||
"params": {
|
||||
"resources": {
|
||||
"path": "/.vib"
|
||||
},
|
||||
"tests_file": "dotnet/goss/goss.yaml",
|
||||
"vars_file": "dotnet/goss/vars.yaml",
|
||||
"remote": {
|
||||
"workload": "deploy-dotnet"
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action_id": "trivy",
|
||||
"params": {
|
||||
|
|
@ -50,4 +64,4 @@
|
|||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue