Skip to content

ci(ghcr): add deploy on GitHub #441

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

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

TartanLeGrand
Copy link

This pull request introduces a new GitHub Actions workflow to automate the publishing of Docker images to the GitHub Container Registry (GHCR). The workflow is triggered on pushes to the main branch and includes steps for building and pushing Docker images.

New GitHub Actions Workflow:

  • .github/workflows/publish-to-ghcr.yml: Added a workflow named "Publish Docker Images to GHCR" that builds and pushes Docker images to GHCR. It includes steps for checking out the repository, logging into GHCR, setting up QEMU and Docker Buildx, and building and pushing Docker images with appropriate tags.

@TartanLeGrand TartanLeGrand mentioned this pull request Apr 25, 2025
context: .
push: true
tags: |
ghcr.io/${{ github.repository_owner }}/redis:latest
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think that we shouldn't set the tag to latest due to versioning scheme expectations which might cause confusion.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Lets use the specific commit SHA only for the time being


on:
push:
branches:
Copy link
Collaborator

Choose a reason for hiding this comment

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

We should also trigger for release/* branches

Copy link
Author

Choose a reason for hiding this comment

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

Ok, what we want ?

  • Trigger on tags ?
  • Trigger on master ?
  • Trigger on release/* ?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I think that we should trigger on pushes to master and release/* and tag with the commit SHA for the time being.

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Build and push Docker images
Copy link
Collaborator

Choose a reason for hiding this comment

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

We provide various platforms for our images, and this action seems like it would only push the amd64 architecture. What do you think about adding the rest of the archs, like we do on Dockerhub?

@TartanLeGrand
Copy link
Author

Simple question why you don't use tags ? 🤔

@adamiBs
Copy link
Collaborator

adamiBs commented Apr 28, 2025

Simple question why you don't use tags ? 🤔

@TartanLeGrand
We didn't need them, but using them seems like a reasonable way to add better git history.

CC @adobrzhansky

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