Repository navigation
CircleCI Migration - #11676
CircleCI Migration#11676
Conversation
| - name: Test build | ||
| run: make | ||
|
|
||
| canary-release: |
There was a problem hiding this comment.
If we merge this PR we will have both GitHub Actions and CircleCI pushing canary builds. Should canary builds for CircleCI be disabled in this PR?
There was a problem hiding this comment.
Everything CircleCI should be removed. I can certainly add the removal of the circleci script if we would like in this PR.
| container_name: ${{ secrets.AZURE_STORAGE_CONTAINER_NAME }} | ||
| connection_string: ${{ secrets.AZURE_STORAGE_CONNECTION_STRING }} |
There was a problem hiding this comment.
Note, these need to be populated prior to merging this PR. Could this be captured in a todo with a checkbox on the PR description. Just to make sure we don't miss it.
| - name: Set Version | ||
| id: set-version | ||
| run: | | ||
| echo "VERSION=$(echo ${GITHUB_REF/refs\/tags\//})" >> $GITHUB_OUTPUT |
There was a problem hiding this comment.
Since this is already filtered for tags, is there a reason we aren't using the GITHUB_REF_NAME variable?
| @@ -0,0 +1,38 @@ | |||
| name: release | |||
There was a problem hiding this comment.
Should this PR remove the deploy from CircleCI? So that the next release does not have two systems pushing it.
There was a problem hiding this comment.
Everything CircleCI should be removed. I can certainly add the removal of the circleci script if we would like in this PR.
c0ad6b7 to
973d821
Compare
There was a problem hiding this comment.
Hey @sabre1041 👋 I closed #11820 in favor of this one. I created that PR only because I thought you said this work had yet to be finished and I got frustrated with Circle again so just busted it out. I see now that you meant your PR just needed to be finished. Kind of good to see though that the solution is roughly the same in both PRs.
As I said in #11820 (comment):
I think there are some things in my PR that would improve yours, but your PR has good things like pinning by sha, and it was first. So let's work on it together from yours and get this in 😄
Here's what 'd like to see merged from the two:
- Pinning by sha:
Nice improvement overall (for everyone else, this is rec'd by GitHub actions hardening doc) - adding
make test buildfrom Circle config:
Both PRs add this because it was missing, and this is clearly the logical place 👍 - adding logic from deploy.sh to Circle config:
- I added them both to a single release workflow, just as they were together in the script
- You added the canary ("main" branch) release to build-pr.yml, and tagged releases to a new release.yml. But I don't think canary releases belong in the PR workflow (honestly that should just be renamed "test", but either way it is just for PRs). I also think there's value in the release to AZ logic in the same file, just so that practically when improvements are made they're done in the same place. The only difference between the two in the script is a single
--overwriteflag, which I noted in my PR
- Very minor. It's not necessary to export
VERSIONfrom a previous build step
| uses: actions/setup-go@v2 | ||
| uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # [email protected] | ||
| with: | ||
| go-version: '1.18' |
There was a problem hiding this comment.
This is more of a question/suggestion than a "we should do this". Curious if there would be any value in using the go-version-file input with the setup-go action. It takes the path to the go.mod file, and uses the version specified there, so when the go version is updated, it would automatically be reflected in the workflows. Link to the docs. My thinking is that it would be one less place to worry about updates/maintenance, but I'm curious to hear others' thoughts.
There was a problem hiding this comment.
thats a new(er) enhancement and I like that it will reduce the number of changes that need to be made when adopting new versions of go.
Thanks for calling it out!
There was a problem hiding this comment.
@lucasrod16 I didn't know about this feature. Very nice!
There was a problem hiding this comment.
@lucasrod16 for now, we have to revert back to specifying the version explicitly. Because it appears there was a regression (mismatch between what's actually in go.mod and the circle tests), that was introduced here
Line 3 in 017785a
in this commit ffa19a4 (see line https://github.com/helm/helm/pull/10912/files#diff-33ef32bf6c23acb95f5902d7097b7a1d5128ca061167ec0716715b0b9eeaa5f6) from this PR #10912. Note the commit comment:
fix circleci tests
We could revert go.mod back to 1.18 here, but that would be scope creep for this PR. Let's do that in a follow-up issue, at which point we could use the go-version-file option.
There was a problem hiding this comment.
@scottrigby ahh I see, thanks for the context! That sounds good, I can write-up an issue and link this discussion for more context.
@sabre1041 apologies for the side-track here
There was a problem hiding this comment.
@scottrigby nevermind I see that you've created a follow-up issue already. Thanks!
Signed-off-by: Andrew Block <[email protected]>
Signed-off-by: Andrew Block <[email protected]>
b424a7d to
35e77cc
Compare
Signed-off-by: Scott Rigby <[email protected]>
Signed-off-by: Scott Rigby <[email protected]>
Signed-off-by: Scott Rigby <[email protected]>
Signed-off-by: Scott Rigby <[email protected]>
| uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # [email protected] | ||
| with: | ||
| go-version: '1.18' | ||
| go-version-file: go.mod |
There was a problem hiding this comment.
See #11676 (comment)
| go-version-file: go.mod | |
| go-version: '1.18' |
| - name: Setup Go | ||
| uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # [email protected] | ||
| with: | ||
| go-version-file: go.mod |
There was a problem hiding this comment.
See above
| go-version-file: go.mod | |
| go-version: '1.18' |
| - name: Setup Go | ||
| uses: actions/setup-go@6edd4406fa81c3da01a34fa6f6343087c207a568 # [email protected] | ||
| with: | ||
| go-version-file: go.mod |
There was a problem hiding this comment.
See above
| go-version-file: go.mod | |
| go-version: '1.18' |
scottrigby
left a comment
There was a problem hiding this comment.
Change back to explicitly setting Go version. See #11676 (comment) and follow-up issue #11838.
6aaa85a to
35e77cc
Compare
Merge 11820 into 11676
Signed-off-by: Andrew Block <[email protected]>
1129986 to
07821c8
Compare
scottrigby
left a comment
There was a problem hiding this comment.
Actions (on PRs) pass, and all actions lgtm! Our plan is to test the build/upload by both merging this PR into main and then cutting a dev tag to test the process for canary.
@sabre1041 I made one more code suggestion (wrapping up my comments above), as a minor speed/simplification improvement. Feel free to merge that suggestion, but either way adding my approval here now. Let's unblock the things 💖
| - name: Set Version | ||
| id: set-version | ||
| run: | | ||
| echo "VERSION=$(echo ${GITHUB_REF_NAME}" >> $GITHUB_OUTPUT | ||
| - name: Build Helm Binaries | ||
| run: | | ||
| make build-cross | ||
| make dist checksum VERSION="${{ steps.set-version.outputs.VERSION }}" |
There was a problem hiding this comment.
Forgot to add this to my PR. Unless there is a practical reason to output the tag, we can skip that and just use it here directly.
| - name: Set Version | |
| id: set-version | |
| run: | | |
| echo "VERSION=$(echo ${GITHUB_REF_NAME}" >> $GITHUB_OUTPUT | |
| - name: Build Helm Binaries | |
| run: | | |
| make build-cross | |
| make dist checksum VERSION="${{ steps.set-version.outputs.VERSION }}" | |
| - name: Build Helm Binaries | |
| run: | | |
| make build-cross | |
| make dist checksum VERSION="${{ github.ref_name }}" |
scottrigby
left a comment
There was a problem hiding this comment.
Also this one. Please check using another workflow name (as this wf does not yet exist to test)
| # Helm | ||
|
|
||
| [](https://circleci.com/gh/helm/helm) | ||
| [](https://github.com/helm/helm/actions?workflow=build-pr) |
There was a problem hiding this comment.
I think we want the release badge for the Readme, right? According to GH UI, I believe this is the right syntax (if no branch query is specified, the default branch - main - is assumed)
| [](https://github.com/helm/helm/actions?workflow=build-pr) | |
| [](https://github.com/helm/helm/actions/workflows/release.yml) |
Signed-off-by: Andrew Block <[email protected]>
|
Excellent! I think we should wait for one other maintainer to approve since you and I both have commits on this |
|
@mattfarina any chance you might be able to review once again? |
Signed-off-by: Andrew Block <[email protected]>
|
🎉 🙌 |
Migrates existing workflow on CircleCI job to GitHub actions native build
Tasks:
AZURE_STORAGE_CONNECTION_STRINGandAZURE_STORAGE_CONTAINER_NAMEas GitHub SecretsBuilds upon #9989