Repository navigation
Support for GitHub Actions and goreleaser - #604
Conversation
dhui
left a comment
There was a problem hiding this comment.
We're getting close to merging this. What are your thoughts/plans for testing? Do you still have a draft of the changelog?
| username: golangmigrate | ||
| password: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
|
||
| - run: echo "::set-env name=SOURCE::$(make echo-source)" |
There was a problem hiding this comment.
I didn't know about workflow commands!
It looks like set-env is deprecated for security reasons. Use $GITHUB_ENV or a step output instead.
There was a problem hiding this comment.
Wow, nice catch! Fixing it right now
There was a problem hiding this comment.
Used $GITHUB_ENV for the fix, it should be good to go. If you find something else, please let me know so I can fix it and we can get this up and running.
I can do a fork and test it with some test accounts.
Yes, I still have it. |
I already tested it (as I started my PR based on those tests). The only big change is the "single source of truth". And we could still test it by creating a v4.14.2-alpha.1 version first, and if it succeeds then go for the v4.14.2 |
dhui
left a comment
There was a problem hiding this comment.
We can test with beta.1 and once release are build properly, we can release a non-prerelease.
I hope specifying beta.X in the tag doesn't break downstream services like package cloud and docker hub...
Resolves #546 , resolves #74
What it does?
It adds a workflow for GitHub actions, which is going to trigger on new tags pushed to the repository.
Steps
ruby/setup-ruby@v1: required for successful gem install of the package_cloud toolactions/setup-go@v2: to setup the wanted go versiondocker/setup-qemu-action@v1anddocker/setup-buildx-action@v1for the multi-arch builddocker/login-action@v1to login to Docker Hubwindows,darwinandlinuxmigrate/migrate:latest:linux/amd64andlinux/arm64migrate/migrate:{{ .Major }}:linux/amd64andlinux/arm64migrate/migrate:{{ .Tag }}:linux/amd64andlinux/arm64migrate/migrate:{{ .Tag }}-amd64:linux/amd64migrate/migrate:{{ .Tag }}-arm64:linux/arm64Note: tried to push images without the
-amd64and-arm64images, but couldn't make it work, maybe in another PR in the future.TODOs:
The workflow requires 3 secrets to be set
PACKAGECLOUD_TOKEN: which is the token for Package Cloud to be able to push new packagesDOCKERHUB_USERNAME: the username of the docker hub user, if I'm right, it'sgolangmigratefor usDOCKERHUB_TOKEN: which is a personal access token for the user we use to push the imagesAfter each release / tag, someone will need to (potentially alter the notes and) publish the draft release created by GoReleaser.
Thank you @johejo for the initial work (#570 )!