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

Docker GHA: Upload Docker images on release #249

Merged
merged 1 commit into from
Jul 24, 2024

Conversation

oxzi
Copy link
Member

@oxzi oxzi commented Jul 24, 2024

With this change, the Docker GitHub Action now creates multi-platform Docker images on releases and pushes those to Docker Hub. The changes were both inspired by the Docker defaults and https://github.com/Icinga/icinga-kubernetes/blob/main/.github/workflows/docker-image.yml.

Note: I am unable to check if the necessary environment variables are already set in this repository. This needs to be done by somebody with the sufficient privileges first. Furthermore, there is no project on Docker Hub so far, maybe it needs to be created first.

@oxzi oxzi requested a review from julianbrost July 24, 2024 06:45
@cla-bot cla-bot bot added the cla/signed CLA is signed by all contributors of a PR label Jul 24, 2024
@julianbrost julianbrost mentioned this pull request Jul 24, 2024
@oxzi oxzi force-pushed the docker-image-upload-on-release branch from 4c9c2ad to 58ca979 Compare July 24, 2024 09:00
@oxzi oxzi requested a review from julianbrost July 24, 2024 09:05
@julianbrost
Copy link
Collaborator

Note: I am unable to check if the necessary environment variables are already set in this repository. This needs to be done by somebody with the sufficient privileges first. Furthermore, there is no project on Docker Hub so far, maybe it needs to be created first.

Looks like someone set them an hour ago (maybe @lippserd, it roughly matches when he commented here 😅), so that should just work now.

@julianbrost julianbrost merged commit cfcb0bf into main Jul 24, 2024
26 checks passed
@julianbrost julianbrost deleted the docker-image-upload-on-release branch July 24, 2024 09:35
@julianbrost
Copy link
Collaborator

main branch from this repo uploaded successfully: https://hub.docker.com/r/icinga/icinga-notifications/tags (job: https://github.com/Icinga/icinga-notifications/actions/runs/10074220195/job/27849849365)

I created a fork to test the release workflow with the merged version, of course fails during docker login, but it would set the correct tags:

Run docker/metadata-action@v5
Context info
Processing images input
Processing tags input
Processing flavor input
Docker image version
Docker tags
  icinga/icinga-notifications:0.1.0
  icinga/icinga-notifications:0.1
  icinga/icinga-notifications:latest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla/signed CLA is signed by all contributors of a PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants