Skip to content

Commit 789a4ab

Browse files
authored
Merge pull request #654 from redhatci/certsuite-collector-vars
certsuite | add optional variables for feeding the collector DB when submitting results
2 parents fab4a87 + 611dc9c commit 789a4ab

File tree

3 files changed

+10
-3
lines changed

3 files changed

+10
-3
lines changed

roles/k8s_best_practices_certsuite/README.md

+2
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ kbpc_log_path | undefined
3535
kbpc_code_src_dir | undefined | If testing a certsuite PR, this variable will be injected from test-runner scripts (used in dci-pipeline and dci-openshift-agent projects) to refer to the file path where the code from the PR is placed in the jumphost, so that it can be used in this role to build a new certsuite container image based on that code.
3636
kbpc_cwe_apikey_path | /opt/cache/cwe-apikey.txt | (Starting from Certsuite v5.4.2) Path to the file containing CWE Hydra API key. It must be generated in Connect UI and saved in this file beforehand.
3737
kbpc_cwe_project_id | undefined | (Starting from Certsuite v5.4.2) Best Practices CNF project ID in Connect UI. Must be retrieved from Connect UI or from the DCI job that created the CNF project.
38+
kbpc_partner_name | "" | Partner name used for feeding the collector DB when submitting a result. This is optional.
39+
kbpc_collector_app_password | "" | Password used for feeding the collector DB when submitting a result. This is optional.
3840

3941
## How to call the role
4042

roles/k8s_best_practices_certsuite/defaults/main.yml

+3
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ kbpc_allow_preflight_insecure: false
1818
# It must be created manually in Connect UI
1919
# Do not forget to define kbpc_cwe_project_id as well
2020
kbpc_cwe_apikey_path: "/opt/cache/cwe-apikey.txt"
21+
# Variables to feed the collector DB when submitting a result with a unique user and pass
22+
kbpc_partner_name: ""
23+
kbpc_collector_app_password: ""
2124
# If this is not set to true, JUnit file will not be created
2225
kbpc_enable_xml_creation: true
2326
## This variable is deprecated, to be deleted when updating backwards compatibility support

roles/k8s_best_practices_certsuite/templates/certsuite_config.yml.j2

+5-3
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,11 @@ connectAPIConfig:
6464
proxyPort: ""
6565
{% endif %}
6666

67+
## collector DB
68+
{% if kbpc_partner_name|length == 0 %}#{% endif %}partnerName: {{ kbpc_partner_name }}
69+
70+
{% if kbpc_collector_app_password|length == 0 %}#{% endif %}collectorAppPassword: {{ kbpc_collector_app_password }}
71+
6772
## fields below are not currently used, leaving placeholder in case they were needed in the future
6873
#managedDeployments:
6974

@@ -81,7 +86,4 @@ connectAPIConfig:
8186

8287
#executedBy: ""
8388

84-
#partnerName: ""
85-
86-
#collectorAppPassword: ""
8789
...

0 commit comments

Comments
 (0)