Skip to content

Commit

Permalink
feat(RELEASE-1146): update release-service to go version 1.22
Browse files Browse the repository at this point in the history
This commit updates the go builder image to version 1.22. In addition
the WORKDIR /build is added due to the new version complaining
as it uses a different build root in the new image.
Signed-off-by: Leandro Mendes <[email protected]>
  • Loading branch information
theflockers committed Oct 8, 2024
1 parent 5bf6972 commit 4b22380
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 6 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Build the manager binary
FROM registry.access.redhat.com/ubi9/go-toolset:1.21.11-9 as builder
FROM brew.registry.redhat.io/rh-osbs/openshift-golang-builder:v1.22 as builder


WORKDIR build/

# Copy the Go Modules manifests
COPY go.mod go.mod
Expand All @@ -20,6 +23,7 @@ COPY syncer/ syncer/
COPY tekton/ tekton/

# Build
RUN go mod vendor
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -a -o manager main.go

ARG ENABLE_WEBHOOKS=true
Expand All @@ -28,7 +32,7 @@ ENV ENABLE_WEBHOOKS=${ENABLE_WEBHOOKS}
# Use ubi-micro as minimal base image to package the manager binary
# See https://catalog.redhat.com/software/containers/ubi9/ubi-micro/615bdf943f6014fa45ae1b58
FROM registry.access.redhat.com/ubi9/ubi-micro:9.4-15
COPY --from=builder /opt/app-root/src/manager /
COPY --from=builder /build/manager /

# It is mandatory to set these labels
LABEL name="Konflux Release Service"
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/konflux-ci/release-service

go 1.21
go 1.22

require (
github.com/enterprise-contract/enterprise-contract-controller/api v0.1.50
Expand All @@ -20,6 +20,7 @@ require (

require (
github.com/antlr4-go/antlr/v4 v4.13.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/emicklei/go-restful/v3 v3.11.2 // indirect
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
github.com/google/cel-go v0.20.0 // indirect
Expand All @@ -45,7 +46,6 @@ require (
github.com/blendle/zapdriver v1.3.1 // indirect
github.com/census-instrumentation/opencensus-proto v0.4.1 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/evanphx/json-patch/v5 v5.9.0 // indirect
github.com/fsnotify/fsnotify v1.7.0 // indirect
github.com/go-kit/log v0.2.1 // indirect
Expand Down

0 comments on commit 4b22380

Please sign in to comment.