Skip to content

Commit

Permalink
chore: update kcl path
Browse files Browse the repository at this point in the history
Signed-off-by: Peefy <[email protected]>
  • Loading branch information
Peefy committed Oct 24, 2024
1 parent 45f6e63 commit 2288b85
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,23 @@ WORKDIR /src
ARG TARGETOS
ARG TARGETARCH

ENV CGO_ENABLED 0
ENV CGO_ENABLED=0

RUN --mount=type=cache,target=/go/pkg --mount=type=cache,target=/root/.cache/go-build GOOS=${TARGETOS} GOARCH=${TARGETARCH} make build

FROM gcr.io/distroless/base-debian11 AS image

COPY --from=build /src/bin/kcl /usr/local/bin/kcl
# Show KCL version
RUN kcl version
RUN /usr/local/bin/kcl version
# Enable kcl works fine
RUN echo 'a=1' | kcl run -
RUN echo 'a=1' | /usr/local/bin/kcl run -
# Install Git Dependency
RUN apt-get update && apt-get install git -y && rm -rf /var/lib/apt/lists/*
# The reason for doing this below is to prevent the
# container from not having write permissions.
ENV KCL_LIB_HOME /tmp
ENV KCL_PKG_PATH /tmp
ENV KCL_CACHE_PATH /tmp
ENV LANG en_US.utf8
ENV KCL_LIB_HOME=/tmp
ENV KCL_PKG_PATH=/tmp
ENV KCL_CACHE_PATH=/tmp
ENV LANG=en_US.utf8
USER nonroot:nonroot

0 comments on commit 2288b85

Please sign in to comment.