-
Notifications
You must be signed in to change notification settings - Fork 49
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: automatically update the appVersion in Chart when release new version #596
feat: automatically update the appVersion in Chart when release new version #596
Conversation
I have raised this PR to test the changes. I couldn't find a better way to test it. |
Yeah, I know. I will test it with you. |
Do you need to approve or something? Not seeing the workflow running. |
@rajeshkio The pipeline need to be triggered by pushing a new tag. Let me test it. |
.github/workflows/release.yaml
Outdated
with: | ||
repository: KusionStack/charts | ||
valueFile: 'charts/karpor/Chart.yaml' | ||
propertyPath: '{"version":"${{ steps.get-chart-version.outputs.new_chart_version }}", "appVersion":"${{ steps.get_version.outputs.VERSION }}"}' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is also a strange error: |
Is there a way for me to test it without disturbing you? |
@rajeshkio You can push the |
I think I know what this error is about. It need to first use checkout action to clone the charts repository locally. You can reference to: https://github.com/fjogeleit/yaml-update-action?tab=readme-ov-file#advanced-example-with-an-separate-target-repository |
Thank you. Today I am a bit busy with office stuff. I will check it soon. |
Yeah, If you need help, please ping me anytime. |
Thank you, but I need a concrete way to test it myself. This is not good, depending on you to find the problem and me just updating the code. |
@rajeshkio Yeah, I know. The pipeline is triggered by tags. Have you tried pushing tags (such as |
Do you mean git tag? I will try with the change |
I think it won't work with the fork repo. It didn't get the docker credentials Run docker/login-action@v2 |
@rajeshkio OK, It seems that the pipeline can be triggered in the fork repository, and unrelated jobs can be deleted. Just keep the update-chart step. |
Sorry bit new to this workflow. You are saying for testing I can remove unrelated jobs and only keep the steps I need in .github/workflows/release.yaml? After testing revert back all the jobs? |
@rajeshkio Yes, just for testing. |
Now it fails with httpError. I am doubting I GITHUB_TOKEN is available while running through fork repo. Can you test and let me know? Run fjogeleit/yaml-update-action@main |
@rajeshkio Yeah, let me try. |
@rajeshkio I also encountered the same problem, maybe it's related to this: Can you modify the target branch to |
6437ccd
to
19b7738
Compare
Done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
#547
What type of PR is this?
/kind feature
What this PR does / why we need it:
Governance: Automatically update the appVersion in the Chart when released
Which issue(s) this PR fixes:
Fixes #547