Skip to content

Commit

Permalink
image is failing to build in CI, maybe this will fix it
Browse files Browse the repository at this point in the history
Signed-off-by: Callum Styan <[email protected]>
  • Loading branch information
cstyan committed Apr 3, 2024
1 parent 27606a3 commit 8a80e43
Showing 1 changed file with 11 additions and 5 deletions.
16 changes: 11 additions & 5 deletions tools/lambda-promtail/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
FROM golang:1.22.2-alpine AS build-image
# RUN yum install -y golang
RUN apk update && apk add git

COPY tools/lambda-promtail /src/lambda-promtail
WORKDIR /src/lambda-promtail

RUN go version
RUN go env -w GOPROXY=direct
ADD . .
RUN go build -o /main -tags lambda.norpc -ldflags="-s -w" lambda-promtail/*.go

RUN apk update && apk upgrade && \
apk add --no-cache bash git
RUN go version

RUN ls -al
RUN go mod download
RUN go build -o /main -tags lambda.norpc -ldflags="-s -w" lambda-promtail/*.go
# copy artifacts to a clean image
FROM public.ecr.aws/lambda/provided:al2
COPY --from=build-image /main /main
Expand Down

0 comments on commit 8a80e43

Please sign in to comment.