Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Image change to debian #55

Merged
merged 3 commits into from
Oct 13, 2023
Merged
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
13 changes: 7 additions & 6 deletions Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ build-cosign:
SAVE ARTIFACT /ko-app/cosign cosign

go-deps:
FROM gcr.io/spectro-images-public/golang:${GOLANG_VERSION}-alpine
FROM gcr.io/spectro-dev-public/edge-native/golang:${GOLANG_VERSION}-debian
WORKDIR /build
COPY go.mod go.sum ./
RUN go mod download
RUN apk update
RUN apt-get update
SAVE ARTIFACT go.mod AS LOCAL go.mod
SAVE ARTIFACT go.sum AS LOCAL go.sum

Expand All @@ -39,11 +39,12 @@ BUILD_GOLANG:
ARG SRC

IF $FIPS_ENABLED
RUN go-build-fips.sh -a -o ${BIN} ./${SRC}
RUN assert-fips.sh ${BIN}
RUN assert-static.sh ${BIN}
ARG LDFLAGS=-s -w -linkmode=external -extldflags=-static
ENV CGO_ENABLED=1
ENV GOEXPERIMENT=boringcrypto
ELSE
RUN go-build.sh -a -o ${BIN} ./${SRC}
ARG LDFLAGS=-s -w
ENV CGO_ENABLED=0
END

RUN go build -ldflags "${LDFLAGS}" -o ${BIN} ./${SRC}
Expand Down
Loading