Skip to content

Commit

Permalink
Fixing Makefile and Containerfile
Browse files Browse the repository at this point in the history
Signed-off-by: Edgar Hernández <23639005+israel-hdez@users.noreply.github.com>
  • Loading branch information
israel-hdez committed Dec 12, 2024
1 parent f6e3fdb commit 879a4f2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion Containerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build the manager binary
FROM registry.access.redhat.com/ubi9/go-toolset:1.21 as builder
FROM registry.access.redhat.com/ubi9/go-toolset:9.5 as builder
ARG TARGETOS
ARG TARGETARCH

Expand All @@ -21,6 +21,7 @@ COPY internal/ internal/
# was called. For example, if we call make docker-build in a local env which has the Apple Silicon M1 SO
# the docker BUILDPLATFORM arg will be linux/arm64 when for Apple x86 it will be linux/amd64. Therefore,
# by leaving it empty we can ensure that the container and binary shipped on it will have the same platform.
USER root
RUN CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -a -o manager cmd/main.go

# Use distroless as minimal base image to package the manager binary
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ endif
# scaffolded by default. However, you might want to replace it to use other
# tools. (i.e. podman)
ENGINE ?= docker # Backwards compatibility
CONTAINER_TOOL ?= $ENGINE
CONTAINER_TOOL ?= $(ENGINE)

# Setting SHELL to bash allows bash commands to be executed by recipes.
# Options are set to exit when a recipe line exits non-zero or a piped command fails.
Expand Down

0 comments on commit 879a4f2

Please sign in to comment.