Skip to content
Open
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
10 changes: 5 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ on:
jobs:
release:
runs-on: ubuntu-latest
env:
# https://goreleaser.com/customization/docker_manifest/
DOCKER_CLI_EXPERIMENTAL: "enabled"
steps:
- name: Code checkout
uses: actions/checkout@v5
Expand Down Expand Up @@ -40,9 +37,12 @@ jobs:
with:
go-version: 1.26.5
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v4
uses: goreleaser/goreleaser-action@v6
with:
version: latest
# Pinned deliberately: an unpinned "latest" means every tag push builds
# with whatever GoReleaser shipped that morning, and a breaking change
# surfaces mid-release, after the tag exists.
version: "v2.17.1"
args: release -f build/.goreleaser.yaml --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
70 changes: 23 additions & 47 deletions build/.goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ builds:
- arm64

archives:
- format: tar.gz
- formats: [tar.gz]
# this name template makes the OS and Arch compatible with the results of `uname`.
name_template: >-
{{ .ProjectName }}_
Expand All @@ -79,10 +79,6 @@ archives:
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
# use zip for windows archives
format_overrides:
- goos: windows
format: zip

changelog:
sort: asc
Expand All @@ -91,53 +87,33 @@ changelog:
- "^docs:"
- "^test:"

dockers:
- goos: linux
goarch: amd64
dockers_v2:
- images:
- "hookdeck/outpost"
tags:
- "{{ .Tag }}"
- "latest"
dockerfile: ./build/Dockerfile.goreleaser
ids:
- outpost
- outpost-server
extra_files:
- build/entrypoint.sh
image_templates:
- "hookdeck/outpost:latest-amd64"
- "hookdeck/outpost:{{ .Tag }}-amd64"
build_flag_templates:
- "--pull"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=repository=https://github.com/hookdeck/outpost"
- "--label=homepage=https://hookdeck.com"
- "--platform=linux/amd64"
- goos: linux
goarch: arm64
dockerfile: ./build/Dockerfile.goreleaser
ids:
- outpost-arm64
- outpost-server
- outpost-server-arm64
extra_files:
- build/entrypoint.sh
image_templates:
- "hookdeck/outpost:latest-arm64"
- "hookdeck/outpost:{{ .Tag }}-arm64"
build_flag_templates:
platforms:
- linux/amd64
- linux/arm64
# No attestations, so the manifest keeps the same two platform entries as
# today. Takes both switches — buildx adds provenance on its own.
sbom: false
flags:
- "--pull"
- "--label=org.opencontainers.image.created={{.Date}}"
- "--label=org.opencontainers.image.name={{.ProjectName}}"
- "--label=org.opencontainers.image.revision={{.FullCommit}}"
- "--label=org.opencontainers.image.version={{.Version}}"
- "--label=repository=https://github.com/hookdeck/outpost"
- "--label=homepage=https://hookdeck.com"
- "--platform=linux/arm64/v8"
docker_manifests:
- name_template: "hookdeck/outpost:latest"
image_templates:
- "hookdeck/outpost:latest-amd64"
- "hookdeck/outpost:latest-arm64"
- name_template: "hookdeck/outpost:{{ .Tag }}"
image_templates:
- "hookdeck/outpost:{{ .Tag }}-amd64"
- "hookdeck/outpost:{{ .Tag }}-arm64"
- "--provenance=false"
labels:
org.opencontainers.image.created: "{{ .Date }}"
org.opencontainers.image.name: "{{ .ProjectName }}"
org.opencontainers.image.revision: "{{ .FullCommit }}"
org.opencontainers.image.version: "{{ .Version }}"
repository: "https://github.com/hookdeck/outpost"
homepage: "https://hookdeck.com"
8 changes: 5 additions & 3 deletions build/Dockerfile.goreleaser
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@ FROM gcr.io/distroless/base-debian13:nonroot
# Copy statically linked shell from busybox for entrypoint script
COPY --from=busybox /bin/sh /bin/sh

# Copy all binaries
COPY outpost /usr/local/bin/outpost
COPY outpost-server /usr/local/bin/outpost-server
# Copy all binaries. GoReleaser stages each platform's artifacts under
# $TARGETPLATFORM/ in the build context, since one buildx build covers both arches.
ARG TARGETPLATFORM
COPY $TARGETPLATFORM/outpost /usr/local/bin/outpost
COPY $TARGETPLATFORM/outpost-server /usr/local/bin/outpost-server

# Copy entrypoint script
COPY build/entrypoint.sh /usr/local/bin/entrypoint.sh
Expand Down
Loading