Files
computer-playbook/.github/workflows/release.yml
T
kevinveenbirkenbach 1086e573c3 refactor(ci): move release helper scripts into scripts/release and drop legacy publish helpers
- Update release workflow to use new script paths
- Remove deprecated build publish/retag-stable scripts
- Fix minor comment typo

https://chatgpt.com/share/69662b40-6938-800f-8ab5-c85424e13db4
2026-01-13 13:36:17 +01:00

68 lines
1.8 KiB
YAML

name: Mark commit as stable
on:
push:
tags:
- "v*"
permissions:
contents: read
packages: write
security-events: write
jobs:
# Run full analyses/tests (gates "stable" marking + image retagging)
code-analyses:
uses: ./.github/workflows/code-analyses.yml
# Only mark stable + retag images if ALL checks passed
release:
needs:
- code-analyses
runs-on: ubuntu-latest
# Always retag version/latest, even if tests fail. Stable is gated below.
if: always() && startsWith(github.ref, 'refs/tags/v')
permissions:
contents: write
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
fetch-depth: 0
fetch-tags: true
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to GHCR
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Determine if this version is the highest (gate stable)
id: highest
shell: bash
run: scripts/release/is-highest.sh
- name: Move 'stable' git tag only if this version is the highest
if: needs.code-analyses.result == 'success' && steps.highest.outputs.is_highest == 'true'
shell: bash
run: scripts/release/move-stable-tag.sh
- name: Retag CI images to version/latest (no rebuild)
shell: bash
env:
OWNER: ${{ github.repository_owner }}
REGISTRY: ghcr.io
REPO_PREFIX: infinito
DISTROS: "arch debian ubuntu fedora centos"
DEFAULT_DISTRO: arch
GITHUB_REF_NAME: ${{ github.ref_name }}
run: scripts/release/retag-ci-images.sh