Skip to content

Bump docker/metadata-action from 5.8.0 to 5.9.0 #17

Bump docker/metadata-action from 5.8.0 to 5.9.0

Bump docker/metadata-action from 5.8.0 to 5.9.0 #17

name: Release Container
# Based on https://vitepress.dev/guide/deploy#github-pages
# Enables automatic publishing of the website to GitHub Pages from main branch.
env:
platforms: linux/amd64,linux/arm64
on:
# run the workflow only for main branch or PRs
push:
branches:
- main
pull_request:
release:
types:
- released
# Allows you to run this workflow manually from the Actions tab for debugging purposes
workflow_dispatch:
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: container
cancel-in-progress: false
jobs:
# Build job
build-web:
name: Build
# Specify runner + deployment step
runs-on: ubuntu-latest
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
packages: write
steps:
# Check out the branch
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
# Fix "Corepack must currently be enabled by running corepack enable in your terminal."
- name: Enable Corepack
run: corepack enable
# Setup Node.js with yarn support
- name: Setup Node
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903
with:
node-version: "lts/*" # Ensures the latest LTS version is used
cache: yarn # npm / pnpm / yarn
# Install javascript dependencies with yarn
- name: Install dependencies
run: yarn install # or pnpm install / yarn install / bun install
# Build the website
- name: Build with VitePress
run: yarn run build # or pnpm docs:build / yarn docs:build / bun run docs:build
# # Publish as container
# publish-as-container:
# permissions:
# contents: read
# packages: write
# name: Build Container Image
# runs-on: ubuntu-latest
# # Add a dependency to the build job
# needs: build-web
# steps:
- name: Log in to GHCR
uses: docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Collect metadata
uses: docker/metadata-action@318604b99e75e41977312d83839a89be02ca4893
id: meta
with:
images: |
ghcr.io/${{ github.repository}}
tags: |
type=semver,pattern={{version}}
type=ref,event=branch
type=ref,event=tag
type=ref,event=pr
type=sha
flavor: |
latest=${{ startsWith(github.ref, 'refs/tags/') }}
- name: Set up QEMU
uses: docker/setup-qemu-action@29109295f81e9208d7d86ff1c6c12d2833863392
with:
platforms: ${{ env.platforms }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435
- name: Build and push Docker image
uses: docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83
with:
context: .
platforms: ${{ env.platforms }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
file: Containerfile
push: true