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

Update krew-index on release tag #911

Merged
merged 1 commit into from
Jan 31, 2024
Merged

Conversation

tpantelis
Copy link
Contributor

Fixes #904

@submariner-bot
Copy link

🤖 Created branch: z_pr911/tpantelis/krew_update

@tpantelis tpantelis force-pushed the krew_update branch 2 times, most recently from 57acd0d to a5d9847 Compare January 30, 2024 03:04
@tpantelis
Copy link
Contributor Author

tpantelis commented Jan 30, 2024

I'm not sure if there's a way to actually test the new GHA now but, once merged, we should be able to manually trigger it from the Actions tab for the 0.16.3 release tag.

@skitt
Copy link
Member

skitt commented Jan 30, 2024

I'm not sure if there's a way to actually test the new GHA now but, once merged, we should be able to manually trigger it from the Actions tab for the 0.16.3 release tag.

See the GHA docs:

podman run -v .krew.yaml:/tmp/template-file.yaml ghcr.io/rajatjindal/krew-release-bot:v0.0.46 \
krew-release-bot template --tag v0.17.0-rc0 --template-file /tmp/template-file.yaml

in the releases project (for v0.17.0-rc0). This produces the index which would be pushed to update the subm.yaml file in the Krew index.

Copy link
Member

@skitt skitt left a comment

Choose a reason for hiding this comment

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

This would fix the job, but there’s a more general problem I think we need to address before we get things working on all releases: since we can only publish one version of the subm plugin, we need to ensure that (a) we only publish actual releases (not rcs etc.) and (b) we only publish the latest release on the latest branch.

@skitt skitt requested a review from Jaanki January 30, 2024 09:06
@tpantelis
Copy link
Contributor Author

This would fix the job, but there’s a more general problem I think we need to address before we get things working on all releases: since we can only publish one version of the subm plugin, we need to ensure that (a) we only publish actual releases (not rcs etc.)

The krew-release-bot takes care of that: "If a release is marked as a 'prerelease' in github, it will not be released to the krew index.".

and (b) we only publish the latest release on the latest branch.

I was thinking about that too. I'm not sure how we can do that....

@tpantelis
Copy link
Contributor Author

I'm not sure if there's a way to actually test the new GHA now but, once merged, we should be able to manually trigger it from the Actions tab for the 0.16.3 release tag.

See the GHA docs:

podman run -v .krew.yaml:/tmp/template-file.yaml ghcr.io/rajatjindal/krew-release-bot:v0.0.46 \
krew-release-bot template --tag v0.17.0-rc0 --template-file /tmp/template-file.yaml

in the releases project (for v0.17.0-rc0). This produces the index which would be pushed to update the subm.yaml file in the Krew index.

yeah that will test the .krew.yaml file but not the GHA.

@skitt
Copy link
Member

skitt commented Jan 30, 2024

The krew-release-bot takes care of that: "If a release is marked as a 'prerelease' in github, it will not be released to the krew index.".

Ah yes, and we mark them correctly already.

@tpantelis
Copy link
Contributor Author

I found a way to get the release tag marked as the latest.

@tpantelis tpantelis requested a review from skitt January 30, 2024 19:00
@skitt skitt merged commit af55efd into submariner-io:devel Jan 31, 2024
19 checks passed
@submariner-bot
Copy link

🤖 Closed branches: [z_pr911/tpantelis/krew_update]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Krew updates fail on release branches
4 participants