Skip to content

Add gh package

Add gh package #1

Workflow file for this run

name: container
on:
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
packages: write
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: false
env:
CONTAINER_REGISTRY: ghcr.io
CONTAINER_IMAGE: ghcr.io/${{ github.actor}}/${{ github.event.repository.name }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Log in to Docker Registry
uses: docker/login-action@v3
with:
registry: ${{ env.CONTAINER_REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Build and push docker image
uses: docker/build-push-action@v6
with:
push: true
tags: |
${{ env.CONTAINER_IMAGE }}:latest
${{ env.CONTAINER_IMAGE }}${{ github.sha }}
cache-from: type=registry,ref=${{ github.actor}}/${{ github.event.repository.name }}:latest
cache-to: type=inline