mirror of
https://github.com/bitnami/containers.git
synced 2026-03-21 23:38:32 +08:00
[bitnami/hyperledger-fabric] ci: 👷 Add VIB integration (#69348)
Signed-off-by: Javier Salmeron Garcia <jsalmeron@vmware.com>
This commit is contained in:
committed by
GitHub
parent
60033117ac
commit
6e9a6dcfea
15
.vib/hyperledger-fabric-peer/goss/goss.yaml
Normal file
15
.vib/hyperledger-fabric-peer/goss/goss.yaml
Normal file
@@ -0,0 +1,15 @@
|
||||
# Copyright Broadcom, Inc. All Rights Reserved.
|
||||
# SPDX-License-Identifier: APACHE-2.0
|
||||
|
||||
gossfile:
|
||||
# Goss tests exclusive to the current container
|
||||
../../hyperledger-fabric-peer/goss/hyperledger-fabric-peer.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: {}
|
||||
../../common/goss/templates/check-spdx.yaml: {}
|
||||
@@ -0,0 +1,10 @@
|
||||
# Copyright Broadcom, Inc. All Rights Reserved.
|
||||
# SPDX-License-Identifier: APACHE-2.0
|
||||
|
||||
command:
|
||||
check-peer:
|
||||
exec: timeout --preserve-status 9 peer node start || true
|
||||
timeout: 15000
|
||||
exit-status: 0
|
||||
stderr:
|
||||
- "Started peer"
|
||||
15
.vib/hyperledger-fabric-peer/goss/vars.yaml
Normal file
15
.vib/hyperledger-fabric-peer/goss/vars.yaml
Normal file
@@ -0,0 +1,15 @@
|
||||
binaries:
|
||||
- peer
|
||||
directories:
|
||||
- mode: "0755"
|
||||
paths:
|
||||
- /opt/bitnami/hyperledger-fabric-peer/etc
|
||||
- mode: "0775"
|
||||
paths:
|
||||
- /opt/bitnami/hyperledger-fabric-peer/var
|
||||
- paths:
|
||||
- /opt/bitnami/hyperledger-fabric-peer
|
||||
root_dir: /opt/bitnami
|
||||
version:
|
||||
bin_name: peer
|
||||
flag: version
|
||||
73
.vib/hyperledger-fabric-peer/vib-verify.json
Normal file
73
.vib/hyperledger-fabric-peer/vib-verify.json
Normal file
@@ -0,0 +1,73 @@
|
||||
{
|
||||
"context": {
|
||||
"resources": {
|
||||
"url": "{SHA_ARCHIVE}",
|
||||
"path": "{VIB_ENV_PATH}"
|
||||
},
|
||||
"runtime_parameters": "Y29tbWFuZDogWyJ0YWlsIiwgIi1mIiwgIi9kZXYvbnVsbCJd"
|
||||
},
|
||||
"phases": {
|
||||
"package": {
|
||||
"actions": [
|
||||
{
|
||||
"action_id": "container-image-package",
|
||||
"params": {
|
||||
"application": {
|
||||
"details": {
|
||||
"name": "{VIB_ENV_CONTAINER}",
|
||||
"tag": "{VIB_ENV_TAG}"
|
||||
}
|
||||
},
|
||||
"architectures": [
|
||||
"linux/amd64",
|
||||
"linux/arm64"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"action_id": "container-image-lint",
|
||||
"params": {
|
||||
"threshold": "error"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
"verify": {
|
||||
"actions": [
|
||||
{
|
||||
"action_id": "goss",
|
||||
"params": {
|
||||
"resources": {
|
||||
"path": "/.vib"
|
||||
},
|
||||
"tests_file": "hyperledger-fabric-peer/goss/goss.yaml",
|
||||
"vars_file": "hyperledger-fabric-peer/goss/vars.yaml",
|
||||
"remote": {
|
||||
"pod": {
|
||||
"workload": "deploy-hyperledger-fabric-peer"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"action_id": "trivy",
|
||||
"params": {
|
||||
"threshold": "LOW",
|
||||
"vuln_type": [
|
||||
"OS"
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"action_id": "grype",
|
||||
"params": {
|
||||
"threshold": "CRITICAL",
|
||||
"package_type": [
|
||||
"OS"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user