Skip to content
This repository has been archived by the owner on Jul 29, 2024. It is now read-only.

add: goreleaser and it's GitHub workflow #37

Merged
merged 1 commit into from
Nov 29, 2021

Conversation

romain-dartigues
Copy link
Contributor

@romain-dartigues romain-dartigues commented Nov 3, 2021

Following #36; we would like to suggest the use of GoReleaser to automate the provision of the binaries.
I would also like to suggest it's use to automatically publish the OCI artifact on DockerHub: https://goreleaser.com/customization/docker/.

This configuration assume that you added to your (GitHub) project Settings > Secrets the (required by goreleaser v0.140.1 or goreleaser/goreleaser-action#261) variables :

  • DOCKER_USERNAME: your Docker Hub username (ie: samcontesse)
  • DOCKER_PASSWORD: the Docker Hub token or password related to the target (ie: ff38b6a6-611b-4537-8d72-84367fb39ea7)
  • DOCKER_TARGET: the Docker Hub target (ie: samcontesse/gitlab-merge-request-resource)
  • DOCKER_REGISTRY (optional): to change the default registry

Edit: sorry for the sudden draft on this PR, it was not ready when I started it ('-_-)

@romain-dartigues romain-dartigues marked this pull request as draft November 4, 2021 13:13
@romain-dartigues romain-dartigues force-pushed the add-goreleaser branch 4 times, most recently from ea834bb to 8cf4aed Compare November 9, 2021 15:44
@romain-dartigues romain-dartigues marked this pull request as ready for review November 9, 2021 15:46
Use [GoReleaser](https://goreleaser.com/) to automate the compilation
and the publication of the OCI artifacts on DockerHub
<https://goreleaser.com/customization/docker/>.

This configuration assume that you added to your (GitHub) project Settings > Secrets
the (required by [goreleaser v0.140.1](https://github.com/till/goreleaser/blob/v0.140.1/scripts/entrypoint.sh)) variables :
- **DOCKER_USERNAME**: your Docker Hub username (ie: `samcontesse`)
- **DOCKER_PASSWORD**: the Docker Hub token *or* password related to the target (ie: `ff38b6a6-611b-4537-8d72-84367fb39ea7`)
- **DOCKER_TARGET**: the Docker Hub target (ie: `samcontesse/gitlab-merge-request-resource`)
- **DOCKER_REGISTRY** (optional): to change the default registry
@samcontesse
Copy link
Owner

Hello @romain-dartigues! Thank you for this nice addition. If there is no rush on your side, I'll have a look at it next week.

@romain-dartigues
Copy link
Contributor Author

Hello @romain-dartigues! Thank you for this nice addition. If there is no rush on your side, I'll have a look at it next week.

No rush at all, and it took me more than one try to get it working on my fork so you should not merge in a hurry.
Thank you for your time.

@samcontesse samcontesse merged commit bb07166 into samcontesse:master Nov 29, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
2 participants