fix(ci): update Hadolint format and improve release workflow for version input

This commit is contained in:
2026-01-04 21:26:36 +00:00
parent d8aa3e0478
commit b7426b2629
2 changed files with 26 additions and 24 deletions

View File

@@ -21,7 +21,8 @@ jobs:
with: with:
dockerfile: Dockerfile dockerfile: Dockerfile
output-file: hadolint.out output-file: hadolint.out
format: sonarqube # format: sonarqube
format: tty
no-fail: true no-fail: true
- name: Print Hadolint results - name: Print Hadolint results

View File

@@ -1,32 +1,31 @@
name: Release name: Build and Release
on: on:
workflow_dispatch: workflow_dispatch:
# push: inputs:
# branches: version:
# - main description: 'Documize version to build (e.g., v5.14.0). Must start with "v" and match an existing Documize release tag.'
schedule: required: true
- cron: '0 9 * * 0' type: string
jobs: jobs:
# tag:
# name: Tag release
# uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/release-with-tag.yaml@main
tag: # create_release:
name: Tag release # name: Create Release
uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/release-with-tag.yaml@main # needs: tag
# uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/create-release-preexisting-tag.yaml@main
# with:
# tag: ${{ needs.tag.outputs.tag_name }}
# body: ${{ needs.tag.outputs.changelog }}
# secrets:
# ACTIONS_TOKEN: ${{ secrets.ACTIONS_TOKEN }}
create_release: docker:
name: Create Release
needs: tag
uses: https://git.tainton.uk/actions/gha-workflows/.gitea/workflows/create-release-preexisting-tag.yaml@main
with:
tag: ${{ needs.tag.outputs.tag_name }}
body: ${{ needs.tag.outputs.changelog }}
secrets:
ACTIONS_TOKEN: ${{ secrets.ACTIONS_TOKEN }}
create_docker:
name: Publish Docker Images name: Publish Docker Images
runs-on: ubuntu-latest runs-on: ubuntu-latest
needs: [tag, create_release] # needs: [tag, create_release]
steps: steps:
- name: Update Docker configuration - name: Update Docker configuration
continue-on-error: true continue-on-error: true
@@ -48,7 +47,7 @@ jobs:
uses: actions/checkout@v6.0.1 uses: actions/checkout@v6.0.1
with: with:
fetch-depth: 0 fetch-depth: 0
ref: ${{ needs.tag.outputs.tag_name }} ref: main
- name: Set up Docker Buildx - name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3 uses: docker/setup-buildx-action@v3
@@ -71,7 +70,7 @@ jobs:
id: meta id: meta
uses: docker/metadata-action@v5 uses: docker/metadata-action@v5
with: with:
tags: type=semver,pattern=v{{version}},value=${{ needs.tag.outputs.tag_name }} tags: type=semver,pattern=v{{version}},value=${{ inputs.version }}
images: | images: |
ghcr.io/${{ vars.GHCR_USERNAME }}/${{ steps.split.outputs.repo }} ghcr.io/${{ vars.GHCR_USERNAME }}/${{ steps.split.outputs.repo }}
${{ vars.PACKAGES_REGISTRY_URL }}/${{ gitea.repository }} ${{ vars.PACKAGES_REGISTRY_URL }}/${{ gitea.repository }}
@@ -90,6 +89,8 @@ jobs:
context: . context: .
push: false push: false
load: true load: true
build-args: |
DOCUMIZE_VERSION=${{ inputs.version }}
annotations: ${{ steps.meta.outputs.annotations }} annotations: ${{ steps.meta.outputs.annotations }}
labels: ${{ steps.meta.outputs.labels }} labels: ${{ steps.meta.outputs.labels }}
tags: ${{ steps.meta.outputs.tags }} tags: ${{ steps.meta.outputs.tags }}