update goreleaser docker builds

This commit is contained in:
swithek 2026-08-05 18:02:50 +02:00
parent f513633401
commit b38f4ec25f
6 changed files with 53 additions and 33 deletions

View File

@ -21,18 +21,21 @@ builds:
- "-trimpath"
ldflags:
- "-s -w"
dockers:
- ids:
dockers_v2:
- id: datagen
ids:
- oxynote-datagen
goos: linux
goarch: amd64
image_templates:
- "ghcr.io/oxynote/datagen:{{ .Version }}"
- "ghcr.io/oxynote/datagen:latest"
dockerfile: ./Dockerfile.dev
build_flag_templates:
- "--pull"
- "--platform=linux/amd64"
images:
- ghcr.io/oxynote/datagen
tags:
- "{{ .Version }}"
- latest
platforms:
- linux/amd64
sbom: false
flags:
- "--provenance=false"
checksum:
disable: true
archives:

View File

@ -1,3 +1,4 @@
FROM gcr.io/distroless/static-debian10:nonroot
COPY oxynote-datagen /
ARG TARGETPLATFORM
COPY ${TARGETPLATFORM}/oxynote-datagen /oxynote-datagen
ENTRYPOINT ["/oxynote-datagen"]

View File

@ -1,3 +1,6 @@
# Build the Docker image
# dockers_v2 snapshot builds load into the local daemon with an arch suffix;
# retag so the dev compose stack can reference a stable :dev tag.
build:
goreleaser release --snapshot --clean
docker tag ghcr.io/oxynote/datagen:dev-amd64 ghcr.io/oxynote/datagen:dev

View File

@ -46,31 +46,39 @@ builds:
- "-X github.com/oxynote/oxynote/server/core/internal/buildinfo._version={{ .Version }}"
- "-X github.com/oxynote/oxynote/server/core/internal/buildinfo._commit={{ .ShortCommit }}"
- "-X github.com/oxynote/oxynote/server/core/internal/buildinfo._timestampString={{ .CommitDate }}"
dockers:
- ids:
dockers_v2:
- id: core
ids:
- core
goos: linux
goarch: amd64
image_templates:
- "ghcr.io/oxynote/core:{{ .Version }}"
- "ghcr.io/oxynote/core:latest"
dockerfile: ./Dockerfile.dev
build_flag_templates:
- "--pull"
- "--platform=linux/amd64"
- "--build-arg=BINARY={{ .ProjectName }}-core"
- ids:
images:
- ghcr.io/oxynote/core
tags:
- "{{ .Version }}"
- latest
platforms:
- linux/amd64
build_args:
BINARY: oxynote-core
sbom: false
flags:
- "--provenance=false"
- id: connector
ids:
- connector
goos: linux
goarch: amd64
image_templates:
- "ghcr.io/oxynote/connector:{{ .Version }}"
- "ghcr.io/oxynote/connector:latest"
dockerfile: ./Dockerfile.dev
build_flag_templates:
- "--pull"
- "--platform=linux/amd64"
- "--build-arg=BINARY={{ .ProjectName }}-connector"
images:
- ghcr.io/oxynote/connector
tags:
- "{{ .Version }}"
- latest
platforms:
- linux/amd64
build_args:
BINARY: oxynote-connector
sbom: false
flags:
- "--provenance=false"
checksum:
disable: true
archives:

View File

@ -1,5 +1,6 @@
FROM gcr.io/distroless/static-debian10:nonroot
ARG TARGETPLATFORM
ARG BINARY
COPY ${BINARY} /app
COPY ${TARGETPLATFORM}/${BINARY} /app
ENTRYPOINT ["/app"]
EXPOSE 8080

View File

@ -1,3 +1,7 @@
# Build the Docker image
# dockers_v2 snapshot builds load into the local daemon with an arch suffix;
# retag so the dev compose stack can reference a stable :dev tag.
build:
goreleaser release --snapshot --clean
docker tag ghcr.io/oxynote/core:dev-amd64 ghcr.io/oxynote/core:dev
docker tag ghcr.io/oxynote/connector:dev-amd64 ghcr.io/oxynote/connector:dev