omniparse 0.4.1

A Rust toolkit for detecting and extracting metadata, text, and content from various file formats
Documentation
name: release-docker

# Build and push the omniparse web service container to GHCR.
#
# Triggers:
#   - Push of a v*.*.* tag (the normal release path)
#   - Manual `workflow_dispatch` from the Actions tab (for hotfix / debug)
#
# Image: ghcr.io/<owner>/omniparse-web
# Tags:  the version (e.g. v0.4.0), the major.minor (e.g. 0.4), and the
#        short commit SHA. `latest` is intentionally NOT pushed on every
#        release — promote a specific tag separately if you want it.

on:
  push:
    tags:
      - 'v*.*.*'
  workflow_dispatch: {}

permissions:
  contents: read
  packages: write

jobs:
  build-push:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Set up QEMU
        uses: docker/setup-qemu-action@v3

      - name: Set up Docker Buildx
        uses: docker/setup-buildx-action@v3

      - name: Log in to GHCR
        uses: docker/login-action@v3
        with:
          registry: ghcr.io
          username: ${{ github.actor }}
          password: ${{ secrets.GITHUB_TOKEN }}

      - name: Compute image metadata
        id: meta
        uses: docker/metadata-action@v5
        with:
          images: ghcr.io/${{ github.repository_owner }}/omniparse-web
          tags: |
            type=ref,event=tag
            type=semver,pattern={{version}}
            type=semver,pattern={{major}}.{{minor}}
            type=sha,format=short

      - name: Build and push (multi-arch)
        uses: docker/build-push-action@v5
        with:
          context: .
          platforms: linux/amd64,linux/arm64
          push: true
          tags: ${{ steps.meta.outputs.tags }}
          labels: ${{ steps.meta.outputs.labels }}
          cache-from: type=gha
          cache-to: type=gha,mode=max