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

handle existing releases idempotently? #65

Open
tony-kerz opened this issue Mar 24, 2020 · 1 comment
Open

handle existing releases idempotently? #65

tony-kerz opened this issue Mar 24, 2020 · 1 comment

Comments

@tony-kerz
Copy link

i have a repo with a series of charts in it and i just wrote a script to iterate over each chart
calling helm package on every chart, and then call cr upload on the result.

works the first time, but then the second time i get 422's.

to account for this situation, do you think cr should ignore or warn on duplicates?

or do you think that the consumer should be smart enough to only generate packages for those things that have changed?

docker run \
  --rm \
  -v /Users/tony/git-alt/helm-charts/build:/build \
  -e CR_OWNER=the-watchmen \
  -e CR_GIT_REPO=helm-charts \
  -e CR_PACKAGE_PATH=/build \
  -e CR_TOKEN=$CR_TOKEN \
  quay.io/helmpack/chart-releaser:v1.0.0-beta.1 \
  cr upload
Error: error creating GitHub release: POST https://api.github.com/repos/the-watchmen/helm-charts/releases: 422 Validation Failed [{Resource:Release Field:tag_name Code:already_exists Message:}]
@sc250024
Copy link

^^ Just ran into this with the above PR from @gjtempleton. What's the advice when the tag already exists? In the above use case, this is for the cluster-autoscaler chart that's used a lot in Kubernetes.

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

2 participants