Skip to content

Commit 9923d81

Browse files
authored
fix(docker): reduce binary size + speed up build (#492)
* fix(docker): reduce burrito binary size * fix(docker): remove go build -a option
1 parent 4f0392a commit 9923d81

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ COPY --from=builder-ui /workspace/dist internal/server/dist
4545
# by leaving it empty we can ensure that the container and binary shipped on it will have the same platform.
4646
ARG VERSION
4747
ENV GOCACHE=/root/.cache/go-build
48-
RUN --mount=type=cache,target=/root/.cache/go-build CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build -a \
49-
-ldflags="\
48+
RUN --mount=type=cache,target=/root/.cache/go-build CGO_ENABLED=0 GOOS=${TARGETOS:-linux} GOARCH=${TARGETARCH} go build \
49+
-ldflags="-w -s \
5050
-X ${PACKAGE}/internal/version.Version=${VERSION} \
5151
-X ${PACKAGE}/internal/version.CommitHash=${COMMIT_HASH} \
5252
-X ${PACKAGE}/internal/version.BuildTimestamp=${BUILD_TIMESTAMP}" \

0 commit comments

Comments
 (0)