From c5d45355a8783986b8fc88e97966f9941b8487a3 Mon Sep 17 00:00:00 2001 From: Harvey Tindall Date: Fri, 26 Jul 2024 16:24:41 +0100 Subject: [PATCH] attempt 2 at BUILT_BY in Docker CI --- .woodpecker/git-docker.yaml | 6 +++--- .woodpecker/stable-docker.yaml | 6 +++--- Dockerfile | 2 ++ 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.woodpecker/git-docker.yaml b/.woodpecker/git-docker.yaml index 39cb6c8..a0b9f4a 100644 --- a/.woodpecker/git-docker.yaml +++ b/.woodpecker/git-docker.yaml @@ -5,9 +5,7 @@ when: steps: - name: build image: docker.io/woodpeckerci/plugin-docker-buildx - environment: - BUILTBY: - from_secret: BUILT_BY + secrets: [ BUILT_BY ] settings: username: from_secret: DOCKER_USERNAME @@ -17,6 +15,8 @@ steps: tags: unstable registry: docker.io platforms: linux/amd64,linux/arm64,linux/arm/v7 + build_args: + - BUILT_BY: $BUILT_BY - name: buildrone image: docker.io/python environment: diff --git a/.woodpecker/stable-docker.yaml b/.woodpecker/stable-docker.yaml index a4cf3a4..f5e59af 100644 --- a/.woodpecker/stable-docker.yaml +++ b/.woodpecker/stable-docker.yaml @@ -5,9 +5,7 @@ when: steps: - name: build image: docker.io/woodpeckerci/plugin-docker-buildx - environment: - BUILTBY: - from_secret: BUILT_BY + secrets: [ BUILT_BY ] settings: username: from_secret: DOCKER_USERNAME @@ -17,6 +15,8 @@ steps: tags: latest registry: docker.io platforms: linux/amd64,linux/arm64,linux/arm/v7 + build_args: + - BUILT_BY: $BUILT_BY - name: buildrone image: docker.io/python environment: diff --git a/Dockerfile b/Dockerfile index fc1537a..4256162 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,6 +15,8 @@ RUN (cd /opt/build; make configuration npm email typescript variants-html bundle FROM --platform=$BUILDPLATFORM golang:latest AS build ARG TARGETARCH ENV GOARCH=$TARGETARCH +ARG BUILT_BY +ENV BUILTBY=$BUILT_BY COPY --from=support /opt/build /opt/build