Fix Docker labels
This commit is contained in:
parent
13cec3d9a9
commit
cf603f0736
12
.github/workflows/build.yml
vendored
12
.github/workflows/build.yml
vendored
@ -41,9 +41,9 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
docker buildx build --platform ${{ steps.prepare.outputs.docker_platforms }} \
|
docker buildx build --platform ${{ steps.prepare.outputs.docker_platforms }} \
|
||||||
--output "type=image,push=false" \
|
--output "type=image,push=false" \
|
||||||
--label "org.label-schema.build-date=${{ steps.prepare.outputs.build_date }}" \
|
--build-arg "BUILD_DATE=${{ steps.prepare.outputs.build_date }}" \
|
||||||
--label "org.label-schema.version=${{ steps.prepare.outputs.version }}" \
|
--build-arg "VCS_REF=${GITHUB_SHA::8}" \
|
||||||
--label "org.label-schema.vcs-ref=${GITHUB_SHA::8}" \
|
--build-arg "VERSION=${{ steps.prepare.outputs.version }}" \
|
||||||
--tag "${{ steps.prepare.outputs.docker_image }}:latest" \
|
--tag "${{ steps.prepare.outputs.docker_image }}:latest" \
|
||||||
--tag "${{ steps.prepare.outputs.docker_image }}:${{ steps.prepare.outputs.version }}" \
|
--tag "${{ steps.prepare.outputs.docker_image }}:${{ steps.prepare.outputs.version }}" \
|
||||||
--file Dockerfile .
|
--file Dockerfile .
|
||||||
@ -60,9 +60,9 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
docker buildx build --platform ${{ steps.prepare.outputs.docker_platforms }} \
|
docker buildx build --platform ${{ steps.prepare.outputs.docker_platforms }} \
|
||||||
--output "type=image,push=true" \
|
--output "type=image,push=true" \
|
||||||
--label "org.label-schema.build-date=${{ steps.prepare.outputs.build_date }}" \
|
--build-arg "BUILD_DATE=${{ steps.prepare.outputs.build_date }}" \
|
||||||
--label "org.label-schema.version=${{ steps.prepare.outputs.version }}" \
|
--build-arg "VCS_REF=${GITHUB_SHA::8}" \
|
||||||
--label "org.label-schema.vcs-ref=${GITHUB_SHA::8}" \
|
--build-arg "VERSION=${{ steps.prepare.outputs.version }}" \
|
||||||
--tag "${{ steps.prepare.outputs.docker_image }}:${{ steps.prepare.outputs.version }}" \
|
--tag "${{ steps.prepare.outputs.docker_image }}:${{ steps.prepare.outputs.version }}" \
|
||||||
--tag "${{ steps.prepare.outputs.docker_image }}:latest" \
|
--tag "${{ steps.prepare.outputs.docker_image }}:latest" \
|
||||||
--file Dockerfile .
|
--file Dockerfile .
|
||||||
|
@ -1,14 +1,21 @@
|
|||||||
# syntax=docker/dockerfile:experimental
|
# syntax=docker/dockerfile:experimental
|
||||||
FROM --platform=${TARGETPLATFORM:-linux/amd64} adoptopenjdk:12-jre-hotspot
|
FROM --platform=${TARGETPLATFORM:-linux/amd64} adoptopenjdk:12-jre-hotspot
|
||||||
|
|
||||||
|
ARG BUILD_DATE
|
||||||
|
ARG VCS_REF
|
||||||
|
ARG VERSION
|
||||||
|
|
||||||
ARG TARGETPLATFORM
|
ARG TARGETPLATFORM
|
||||||
ARG BUILDPLATFORM
|
ARG BUILDPLATFORM
|
||||||
RUN printf "I am running on ${BUILDPLATFORM:-linux/amd64}, building for ${TARGETPLATFORM:-linux/amd64}\n$(uname -a)\n"
|
RUN printf "I am running on ${BUILDPLATFORM:-linux/amd64}, building for ${TARGETPLATFORM:-linux/amd64}\n$(uname -a)\n"
|
||||||
|
|
||||||
LABEL maintainer="CrazyMax" \
|
LABEL maintainer="CrazyMax" \
|
||||||
|
org.label-schema.build-date=$BUILD_DATE \
|
||||||
org.label-schema.name="jetbrains-license-server" \
|
org.label-schema.name="jetbrains-license-server" \
|
||||||
org.label-schema.description="JetBrains License Server" \
|
org.label-schema.description="JetBrains License Server" \
|
||||||
|
org.label-schema.version=$VERSION \
|
||||||
org.label-schema.url="https://github.com/crazy-max/docker-jetbrains-license-server" \
|
org.label-schema.url="https://github.com/crazy-max/docker-jetbrains-license-server" \
|
||||||
|
org.label-schema.vcs-ref=$VCS_REF \
|
||||||
org.label-schema.vcs-url="https://github.com/crazy-max/docker-jetbrains-license-server" \
|
org.label-schema.vcs-url="https://github.com/crazy-max/docker-jetbrains-license-server" \
|
||||||
org.label-schema.vendor="CrazyMax" \
|
org.label-schema.vendor="CrazyMax" \
|
||||||
org.label-schema.schema-version="1.0"
|
org.label-schema.schema-version="1.0"
|
||||||
|
Loading…
Reference in New Issue
Block a user