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

added github actions to build and release #325

Merged
merged 5 commits into from
Jan 3, 2022
Merged

added github actions to build and release #325

merged 5 commits into from
Jan 3, 2022

Conversation

kbudde
Copy link
Contributor

@kbudde kbudde commented Dec 28, 2021

Hi,

I've added a github action to build and deploy as travis was doing it before.
You must add the following secrets to your repository:

  • DOCKERHUB_USERNAME
  • DOCKERHUB_TOKEN

#323

@kbudde kbudde mentioned this pull request Dec 28, 2021
Copy link
Collaborator

@davideicardi davideicardi left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you very much!

Maybe we should delete .github/workflows/maven.yml ?

I don't have permission to setup github actions variables, I think we need @ekoutanov .

@kbudde
Copy link
Contributor Author

kbudde commented Dec 28, 2021

The maven.yml will also run on PRs. Therefore I think it's better to keep it.

@mcs
Copy link
Contributor

mcs commented Dec 28, 2021

Feel free to do whatever you want with the maven.yml. I just added it to my former PR because there "just" was Travis CI which I could not use for server-side test execution.

.github/workflows/build.yml Outdated Show resolved Hide resolved
run github release action first to precent overwriting existing releases.
@kbudde
Copy link
Contributor Author

kbudde commented Dec 30, 2021

@ekoutanov I would really love to see a release without log4j issues.
Can you please set up the secrets?

@ekoutanov
Copy link
Member

I'll try to get around to it.

@davideicardi
Copy link
Collaborator

@kbudde @ekoutanov @mcs
According to #260 Bintray is no longer available. Maybe we should use Github release only?

https://github.com/marketplace/actions/upload-files-to-a-github-release

@ekoutanov
Copy link
Member

@kbudde @ekoutanov @mcs According to #260 Bintray is no longer available. Maybe we should use Github release only?

https://github.com/marketplace/actions/upload-files-to-a-github-release

yeah, Bintray's kaput. We can skip it if the binaries can be uploaded elsewhere.

@kbudde
Copy link
Contributor Author

kbudde commented Dec 30, 2021

@davideicardi , @ekoutanov I fixed it and updated the description.

The github workflow will now create the github release and a tag(!) if the version in pom.xml does end on "-SNAPSHOT".
The github release has the kafdrop-VERSION.jar attached.
See here for an example: https://github.com/kbudde/kafdrop/releases/tag/3.28.0

@ekoutanov only the dockerhub token is needed anymore.
Bintray was removed. For github the default token is used.

I've also cleaned up the CI files.

Release workflow:

  • Update pom.xml (remove -SNAPSHOT from version)
  • Commit and push to master
  • Update pom.xml (increment version + add suffix -SNAPSHOT again)
  • Commit and push

Each commit on master will push container to dockerhub: obsidiandynamics/kafdrop:*version* (e.g. obsidiandynamics/kafdrop:3.28.0-SNAPSHOT, obsidiandynamics/kafdrop:3.28.0)
If the version is not a snapshot release, another image is pushed: obsidiandynamics/kafdrop:latest.
So latest will always point to last release.

@davideicardi
Copy link
Collaborator

Great work @kbudde ! Thank you!

@ekoutanov
Copy link
Member

ekoutanov commented Jan 3, 2022

Added secrets

@ekoutanov ekoutanov merged commit a27366e into obsidiandynamics:master Jan 3, 2022
@davideicardi
Copy link
Collaborator

@kbudde The new action seems to work without problems!
I just released a new version 3.28.0.

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.

4 participants