Skip to content

Commit 4019027

Browse files
authored
# What does this PR do? revert llamastack#2855 to unblock release (running out of disk space) Error here: https://github.com/llamastack/llama-stack-ops/actions/runs/16579983004/job/46893549312 ## Test Plan
1 parent e189f65 commit 4019027

File tree

1 file changed

+8
-17
lines changed

1 file changed

+8
-17
lines changed

llama_stack/distribution/build_container.sh

Lines changed: 8 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,6 @@ UV_HTTP_TIMEOUT=${UV_HTTP_TIMEOUT:-500}
1818

1919
# mounting is not supported by docker buildx, so we use COPY instead
2020
USE_COPY_NOT_MOUNT=${USE_COPY_NOT_MOUNT:-}
21-
22-
# Mount command for cache container .cache, can be overridden by the user if needed
23-
MOUNT_CACHE=${MOUNT_CACHE:-"--mount=type=cache,id=llama-stack-cache,target=/root/.cache"}
24-
2521
# Path to the run.yaml file in the container
2622
RUN_CONFIG_PATH=/app/run.yaml
2723

@@ -176,18 +172,13 @@ RUN pip install uv
176172
EOF
177173
fi
178174

179-
# Set the link mode to copy so that uv doesn't attempt to symlink to the cache directory
180-
add_to_container << EOF
181-
ENV UV_LINK_MODE=copy
182-
EOF
183-
184175
# Add pip dependencies first since llama-stack is what will change most often
185176
# so we can reuse layers.
186177
if [ -n "$normal_deps" ]; then
187178
read -ra pip_args <<< "$normal_deps"
188179
quoted_deps=$(printf " %q" "${pip_args[@]}")
189180
add_to_container << EOF
190-
RUN $MOUNT_CACHE uv pip install $quoted_deps
181+
RUN uv pip install --no-cache $quoted_deps
191182
EOF
192183
fi
193184

@@ -197,7 +188,7 @@ if [ -n "$optional_deps" ]; then
197188
read -ra pip_args <<< "$part"
198189
quoted_deps=$(printf " %q" "${pip_args[@]}")
199190
add_to_container <<EOF
200-
RUN $MOUNT_CACHE uv pip install $quoted_deps
191+
RUN uv pip install --no-cache $quoted_deps
201192
EOF
202193
done
203194
fi
@@ -208,10 +199,10 @@ if [ -n "$external_provider_deps" ]; then
208199
read -ra pip_args <<< "$part"
209200
quoted_deps=$(printf " %q" "${pip_args[@]}")
210201
add_to_container <<EOF
211-
RUN $MOUNT_CACHE uv pip install $quoted_deps
202+
RUN uv pip install --no-cache $quoted_deps
212203
EOF
213204
add_to_container <<EOF
214-
RUN python3 - <<PYTHON | $MOUNT_CACHE uv pip install -r -
205+
RUN python3 - <<PYTHON | uv pip install --no-cache -r -
215206
import importlib
216207
import sys
217208
@@ -293,7 +284,7 @@ COPY $dir $mount_point
293284
EOF
294285
fi
295286
add_to_container << EOF
296-
RUN $MOUNT_CACHE uv pip install -e $mount_point
287+
RUN uv pip install --no-cache -e $mount_point
297288
EOF
298289
}
299290

@@ -308,10 +299,10 @@ else
308299
if [ -n "$TEST_PYPI_VERSION" ]; then
309300
# these packages are damaged in test-pypi, so install them first
310301
add_to_container << EOF
311-
RUN $MOUNT_CACHE uv pip install fastapi libcst
302+
RUN uv pip install --no-cache fastapi libcst
312303
EOF
313304
add_to_container << EOF
314-
RUN $MOUNT_CACHE uv pip install --extra-index-url https://test.pypi.org/simple/ \
305+
RUN uv pip install --no-cache --extra-index-url https://test.pypi.org/simple/ \
315306
--index-strategy unsafe-best-match \
316307
llama-stack==$TEST_PYPI_VERSION
317308
@@ -323,7 +314,7 @@ EOF
323314
SPEC_VERSION="llama-stack"
324315
fi
325316
add_to_container << EOF
326-
RUN $MOUNT_CACHE uv pip install $SPEC_VERSION
317+
RUN uv pip install --no-cache $SPEC_VERSION
327318
EOF
328319
fi
329320
fi

0 commit comments

Comments
 (0)