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

Add artifacts to builds, add docker hub automatic releases, add githu… #40

Merged
merged 2 commits into from
Sep 30, 2024

Conversation

evolvedlight
Copy link
Contributor

@evolvedlight evolvedlight commented Sep 28, 2024

This addresses #35

It requires that the DOCKER_USERNAME and DOCKER_PASSWORD is set on your repository.

Example results: https://hub.docker.com/repository/docker/evolvedlight/kvrocks-exporter/general

https://github.com/evolvedlight/kvrocks_exporter/releases/tag/v1.0.17

In addition, each PR will create artifacts that could be tested.

I removed gox from the makefile as the upstream tool appears archived.
I also replaced the goreleaser multidocker build with kos as it seems easier to maintain.

@git-hulk
Copy link
Member

@evolvedlight Thanks for your contributions.

export CGO_ENABLED=0 ; \
gox -os=$(OS) -arch=$(ARCH) -verbose -rebuild -ldflags $(GO_LDFLAGS) -output ".build/kvrocks_exporter" && \
echo "done"
goreleaser release --clean -f .github/goreleaser.yml
Copy link
Member

@git-hulk git-hulk Sep 29, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could we separate the build and release binary into two targets? That said, we can have make build to build to binary which doesn't depend on goreleaser, and add the target make release for releasing propose. What do you think about this?

Rest are good to me.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, made that change. My opinion I guess would be that this goreleaser step is never used and the release is only done by CI. Good then that the make build only makes a local build with no dependencies.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And thanks for checking the PR - I'd suggest that assuming it works, I'd make another PR to update the readme a bit to also point to the docker hub reference.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, thank you!

@git-hulk git-hulk merged commit c3ddc0f into RocksLabs:master Sep 30, 2024
1 check passed
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

Successfully merging this pull request may close these issues.

2 participants