Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(RELEASE-1267): rename cve field in populate release notes #653

Merged
merged 1 commit into from
Nov 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions schema/dataKeys.json
Original file line number Diff line number Diff line change
Expand Up @@ -226,9 +226,9 @@
"additionalProperties": {
"type": "object",
"properties": {
"components": {
"packages": {
"type": "array",
"description": "A list of CVEs fixed e.g. [ 'pkg:golang/golang.org/x/net/http2@1.11.1' ]",
"description": "A list of packages that fixed the CVE e.g. [ 'pkg:golang/golang.org/x/net/http2@1.11.1' ]",
"items": {
"type": "string"
}
Expand Down
3 changes: 3 additions & 0 deletions tasks/populate-release-notes-images/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ in place so that downstream tasks relying on the releaseNotes data can use it.
| dataPath | Path to the JSON string of the merged data to update | No | - |
| snapshotPath | Path to the JSON string of the mapped Snapshot in the data workspace | No | - |

## Changes in 2.2.3
* Rename `components` in the CVE struct to `packages`

## Changes in 2.2.2
* Add component association information

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ kind: Task
metadata:
name: populate-release-notes-images
labels:
app.kubernetes.io/version: "2.2.2"
app.kubernetes.io/version: "2.2.3"
annotations:
tekton.dev/pipelines.minVersion: "0.12.1"
tekton.dev/tags: release
Expand Down Expand Up @@ -67,7 +67,7 @@ spec:
cveJson=$(jq -n \
--arg id $(jq -r '.key' <<< $cve) \
--argjson packages $(jq -c '.packages' <<< $cve) \
'{($id): {"components": $packages}}')
'{($id): {"packages": $packages}}')
CVEsJson=$(jq --argjson cve "$cveJson" '.cves.fixed += $cve' <<< $CVEsJson)
done
# Add one entry per arch (amd64 for example)
Expand Down