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: apko publish: write all published tags to a file and publish the tags #809

Open
joemiller opened this issue Jul 17, 2023 · 0 comments

Comments

@joemiller
Copy link
Contributor

joemiller commented Jul 17, 2023

/The existing --stage-tags tags.txt flag for apko publish will write all tags, including tags generated via --package-version-tag and --package-version-tag-stem to a file but it disables publishing those tags.

It would be helpful to have a version of this flag that wrote the published tags as well as published them. This would allow scripts/tooling that want to use apko publish to handle publishing and also have a simple way to discover and report on all of the published tags.

It's possible to work around this using something like crane, eg:

digest=$(apko publish --package-version-tag go-1.20 --stage-tags tags.txt ./apko.yaml registry/go:latest)
for i in $(cat tags.txt); do
  crane tag "$digest" $i   # actually i think the tags.txt contains fully qualified image name so you'd need to strip off the `:tag` from the end before passing $i into `crane`
done

But it would be ideal to not have to do this.

I would be happy to send a PR for this if it's something the project would likely accept? What would an appropriate flag name be?

@joemiller joemiller changed the title feat: apko publish: write all published tags to a file feat: apko publish: write all published tags to a file and publish the tags Jul 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant