Skip to content

Commit

Permalink
feat: update Dockerfile to use debian:12-slim and streamline package …
Browse files Browse the repository at this point in the history
…installation
  • Loading branch information
Gyarbij committed Dec 20, 2024
1 parent 82cc51e commit 65db36c
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,19 @@ COPY . .
RUN go get github.com/joho/godotenv
RUN CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o azure-oai-proxy .

FROM gcr.io/distroless/base-debian12
# Use debian:12-slim instead of distroless for installing additional tools
FROM debian:12-slim
COPY --from=builder /build/azure-oai-proxy /
RUN apt-get update && apt-get install -y ca-certificates && apt-get install -y openssh-client
RUN apt-get update && apt-get install -y curl
RUN curl -sSL https://sdk.cloud.google.com | bash
ENV PATH="$PATH:/opt/google-cloud-sdk/bin"

# Install required packages
RUN apt-get update && \
apt-get install -y ca-certificates openssh-client curl && \
curl -sSL https://sdk.cloud.google.com | bash && \
apt-get clean && \
rm -rf /var/lib/apt/lists/*

ENV PATH="$PATH:/root/google-cloud-sdk/bin"
RUN gcloud init

EXPOSE 11437
ENTRYPOINT ["/azure-oai-proxy"]

0 comments on commit 65db36c

Please sign in to comment.