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

feat: Generate OpenVX data for every release #2276

Merged
merged 5 commits into from
Dec 19, 2023

Conversation

shafeeqes
Copy link
Contributor

What this PR does / why we need it:
This PR adds a github workflow action to generate OpenVX data for every release.

#SecuritySlam

Which issue(s) this PR fixes:
Fixes part of #2274

Signed-off-by: Shafeeque E S <shafeeque.e.s@sap.com>
@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Dec 15, 2023
@k8s-ci-robot k8s-ci-robot added the needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. label Dec 15, 2023
@k8s-ci-robot
Copy link
Contributor

This issue is currently awaiting triage.

If kube-state-metrics contributors determine this is a relevant issue, they will accept it by applying the triage/accepted label and provide further guidance.

The triage/accepted label can be added by org members by writing /triage accepted in a comment.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Dec 15, 2023
@shafeeqes shafeeqes changed the title Generate OpenVX data for every release feat: Generate OpenVX data for every release Dec 15, 2023
@mrueg
Copy link
Member

mrueg commented Dec 15, 2023

/ok-to-test

@k8s-ci-robot k8s-ci-robot added the ok-to-test Indicates a non-member PR verified by an org member that is safe to test. label Dec 15, 2023
.github/workflows/openvex.yaml Outdated Show resolved Hide resolved
.github/workflows/openvex.yaml Outdated Show resolved Hide resolved
Signed-off-by: Shafeeque E S <shafeeque.e.s@sap.com>
Signed-off-by: Shafeeque E S <shafeeque.e.s@sap.com>
Copy link
Member

@rexagod rexagod left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for picking this up! 🎉

.github/workflows/openvex.yml Outdated Show resolved Hide resolved
.github/workflows/openvex.yml Outdated Show resolved Hide resolved
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
- uses: openvex/generate-vex@31b415924ea0d72ed5f2640f1dee59dea6c2770b
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we pin this to the latest major as well?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see openvex has not tagged any release yet. Can we pin this to the latest c59881b41451d7ccba5c3b74cd195382b8971fcd commit then?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've raised an issue regarding releases: openvex/generate-vex#2.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see openvex has not tagged any release yet. Can we pin this to the latest c59881b41451d7ccba5c3b74cd195382b8971fcd commit then?

Done.

- name: Checkout code
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
- name: Set env
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm afraid running openvex for all releases would generate unnecessary noise, since we generally only maintain the latest release branches. Can we restrict this to that only? cc @mrueg

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is restricted only to a pushed tag. See line 7

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, better to run on releases than tags.

.github/workflows/openvex.yml Show resolved Hide resolved
# Refer: https://github.com/openvex/vexctl#operational-model
name: Run vexctl
with:
product: pkg:golang/kubernetes/kube-state-metrics@${{ env.RELEASE_VERSION }}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
product: pkg:golang/kubernetes/kube-state-metrics@${{ env.RELEASE_VERSION }}
product: pkg:golang/k8s.io/kube-state-metrics/v2@${{ env.RELEASE_VERSION }}

should this be the golang package name?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the v2? Is it not covered by the env?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

v2 is because it expects the full name of the golang package.

@mrueg
Copy link
Member

mrueg commented Dec 19, 2023

/lgtm

Thanks! Right now this will output in Github Actions log so it should not block any release.

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Dec 19, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: mrueg, shafeeqes

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 19, 2023
@k8s-ci-robot k8s-ci-robot merged commit 5041137 into kubernetes:main Dec 19, 2023
12 checks passed
@shafeeqes shafeeqes deleted the enh/vex-2 branch January 17, 2024 03:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants