Shared Jenkins library which all ODS projects & components use - provisioning, SonarQube code scanning, Nexus publishing, OpenShift template based deployments and repository orchestration
Apache License 2.0
69
stars
57
forks
source link
TIR - remove dynamic pod data and surface helm status #1135
If helm is used for deployment, the components deployed by helm are no longer listed as toplevel elements in the TIR. Instead the helm release is represented by its status so that users will see tables under:
The DeploymentStatus has rows surfacing the releaseName, releaseRevision, namespace, deployStatus, deployDescription, lastDeployed and resources.
Here an example of the resources:
"Deployment: backend-helm-monorepo-chart-component-a, backend- helm-monorepo-chart-component-b, Service: backend-helm-monorepo-chart"
Non-Helm deployments are surfaced as before.
Further change notes:
To avoid CPS issues in Jenkins all types were using their own file and the Immutable annotation was avoided.
Type HelmStatusData captures helm status with high fidelity whereas HelmStatusSimpleData captures shallower information in particular omitting the details of resources except their names and kinds. This approach simplifies the json Helm status json parsing code while keeping the consuming code relatively lean.
In the deployment artifact the simplified helmStatus is kept under key 'helmStatus' in the deploymentMean information. Which is also written to ods-deployments.json by DeploymentDescriptor.
PodData fields capturing dynamic data where removed, except for the podName which has a prefix useful for correlating dynamic data with pods. At the moment this is still needed for both tailor and helm deployments. The code which finds this named pods did require retry logic even for helm installs using --atomic.
This change is meant to be released with the change in https://github.com/opendevstack/ods-document-generation-templates/pull/145 although there is no technical coupling at the moment.
If helm is used for deployment, the components deployed by helm are no longer listed as toplevel elements in the TIR. Instead the helm release is represented by its status so that users will see tables under:
Deployment Resource:-deploymentMean
Deployment Resource: -deploymentStatus
The DeploymentStatus has rows surfacing the releaseName, releaseRevision, namespace, deployStatus, deployDescription, lastDeployed and resources.
Here an example of the resources: "Deployment: backend-helm-monorepo-chart-component-a, backend- helm-monorepo-chart-component-b, Service: backend-helm-monorepo-chart"
Non-Helm deployments are surfaced as before.
Further change notes:
ods-deployments.json
by DeploymentDescriptor.