Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dockerfile labels #58

Merged
merged 2 commits into from
May 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 1 addition & 15 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,28 +53,14 @@ jobs:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Generate image metadata
if: steps.cache.outputs.cache-hit != 'true'
id: meta
uses: docker/metadata-action@v4
with:
images: ${{ env.IMAGE_NAME }}
labels: |
org.opencontainers.image.title=OCR-D Manager
org.opencontainers.image.version=${{ github.event.inputs.image-tag }}
org.opencontainers.image.revision=${{ env.vcs_ref }}
org.opencontainers.image.created=${{ env.build_date }}
tags: ${{ github.event.inputs.image-tag }}

- name: Build the OCR-D Manager image "${{ env.IMAGE_NAME }}:${{ github.event.inputs.image-tag }}" and deploy to GitHub Container Repository
if: steps.cache.outputs.cache-hit != 'true'
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
tags: ${{ env.IMAGE_NAME }}:${{ github.event.inputs.image-tag }}
build-args: |
BUILD_DATE=${{ env.build_date }}
VCS_REF=${{ env.vcs_ref }}
Expand Down
10 changes: 9 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,22 @@
# ocrd/core # ubuntu:18.04
FROM ocrd/core:latest

MAINTAINER markus.weigelt@slub-dresden.de
ARG VCS_REF
ARG BUILD_DATE
LABEL \
maintainer="https://slub-dresden.de" \
org.label-schema.vendor="Saxon State and University Library Dresden" \
org.label-schema.name="OCR-D Manager" \
org.label-schema.vcs-ref=$VCS_REF \
org.label-schema.vcs-url="https://github.com/slub/ocrd_manager" \
org.label-schema.build-date=$BUILD_DATE
org.opencontainers.image.vendor="Saxon State and University Library Dresden" \
org.opencontainers.image.title="OCR-D Manager" \
org.opencontainers.image.description="Frontend for OCR-D Controller"
org.opencontainers.image.source="https://github.com/slub/ocrd_manager"
org.opencontainers.image.documentation="https://github.com/slub/ocrd_manager/blob/${VCS_REF}/README.md"
org.opencontainers.image.revision=$VCS_REF
org.opencontainers.image.created=$BUILD_DATE

ARG KITODO_MQ_CLIENT_VERSION=0.2

Expand Down