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

ci: migrate to GitHub Container Registry #82

Closed
wants to merge 3 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
uses: actions/[email protected]

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1.1.1
uses: docker/setup-buildx-action@v2
with:
driver-opts: network=host

Expand All @@ -97,7 +97,7 @@ jobs:
${{ runner.os }}-buildx-

- name: Build & push the Fedora base image to local registry
uses: docker/build-push-action@v2.2.2
uses: docker/build-push-action@v3
with:
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
Expand All @@ -107,11 +107,12 @@ jobs:
push: true
tags: localhost:5000/fedora-base:latest

- name: Login to Docker Hub
uses: docker/login-action@v1.8.0
- name: Login to GitHub Container Registry
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Write the Dockerfile for the ${{ matrix.runtime.name }} runtime
run: |
Expand All @@ -122,10 +123,10 @@ jobs:
RUN --security=insecure flatpak install -y --noninteractive ${{matrix.runtime.remote}} ${{ matrix.runtime.packages }}

- name: Build & push the ${{ matrix.runtime.name }} image to Docker Hub
uses: docker/build-push-action@v2.2.2
uses: docker/build-push-action@v3
with:
allow: security.insecure
context: .
file: ${{ matrix.runtime.name }}.Dockerfile
push: true
tags: bilelmoussaoui/flatpak-github-actions:${{ matrix.runtime.name }}
tags: ghcr.io/${{ github.repository }}:${{ matrix.runtime.name }}
4 changes: 2 additions & 2 deletions .github/workflows/flatpak-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
name: Flatpak Builder
runs-on: ubuntu-latest
container:
image: bilelmoussaoui/flatpak-github-actions:gnome-40
image: ghcr.io/${{ github.repository }}:gnome-40
options: --privileged
strategy:
fail-fast: false
Expand All @@ -23,7 +23,7 @@ jobs:
dnf -y install docker
- name: Set up QEMU
if: ${{ matrix.arch != 'x86_64' }}
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v2
with:
platforms: arm64
- uses: ./flatpak-builder
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM fedora:latest
FROM registry.fedoraproject.org/fedora:latest

RUN dnf update -y && \
dnf install -y dbus-daemon flatpak flatpak-builder git-lfs python3-aiohttp python3-tenacity python3-gobject xorg-x11-server-Xvfb ccache zstd && \
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ jobs:
dnf -y install docker
- name: Set up QEMU
id: qemu
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v2
with:
platforms: arm64
- uses: flatpak/flatpak-github-actions/flatpak-builder@v4
Expand Down