Skip to content

Commit 0073975

Browse files
authored
Merge pull request #149 from codelion/codelion-patch-2
Update Dockerfile.proxy_only
2 parents ebcd6e6 + 547680b commit 0073975

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed

Dockerfile.proxy_only

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,14 @@ ENV OPTILLM_PORT=$PORT
1010
WORKDIR /app
1111

1212
# Install system dependencies
13-
RUN apt-get update && apt-get install -y --no-install-recommends \
14-
build-essential \
15-
python3-dev \
16-
gcc \
17-
g++ \
18-
&& rm -rf /var/lib/apt/lists/*
13+
RUN --mount=type=cache,target=/var/cache/apt \
14+
--mount=type=cache,target=/var/lib/apt \
15+
apt-get update && apt-get install -y --no-install-recommends \
16+
build-essential \
17+
python3-dev \
18+
gcc \
19+
g++ \
20+
&& rm -rf /var/lib/apt/lists/*
1921

2022
# Copy only the requirements file first to leverage Docker cache
2123
COPY requirements_proxy_only.txt .
@@ -31,9 +33,11 @@ LABEL org.opencontainers.image.description="OptiLLM proxy-only image for API rou
3133
LABEL org.opencontainers.image.licenses=Apache-2.0
3234

3335
# Install curl for the healthcheck
34-
RUN apt-get update && apt-get install -y --no-install-recommends \
35-
curl && \
36-
apt-get clean && rm -rf /var/lib/apt/lists/*
36+
RUN --mount=type=cache,target=/var/cache/apt \
37+
--mount=type=cache,target=/var/lib/apt \
38+
apt-get update && apt-get install -y --no-install-recommends \
39+
curl && \
40+
apt-get clean && rm -rf /var/lib/apt/lists/*
3741

3842
# Set working directory
3943
WORKDIR /app

0 commit comments

Comments
 (0)