Skip to content

Commit ae2c4c3

Browse files
committed
set UV_LINK_MODE=copy for all uv pip install commands in codeserver/ubi9-python-3.12 Dockerfile (#2356)
1 parent aac3c08 commit ae2c4c3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

codeserver/ubi9-python-3.12/Dockerfile.cpu

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ RUN --mount=type=cache,target=/root/.cache/uv \
5151
source ./devel_env_setup.sh && \
5252
# This may have to download and compile some dependencies, and as we don't lock requirements from `build-system.requires`,
5353
# we often don't know the correct hashes and `--require-hashes` would therefore fail on non amd64, where building is common.
54-
uv pip install --strict --no-deps --refresh --no-config --no-progress --verify-hashes --compile-bytecode --index-strategy=unsafe-best-match --requirements=./pylock.toml
54+
UV_LINK_MODE=copy uv pip install --strict --no-deps --refresh --no-config --no-progress --verify-hashes --compile-bytecode --index-strategy=unsafe-best-match --requirements=./pylock.toml
5555

5656
# dummy file to make image build wait for this stage
5757
RUN touch /tmp/control
@@ -231,10 +231,10 @@ RUN --mount=type=cache,target=/root/.cache/uv \
231231
echo "Installing softwares and packages" && \
232232
# we can ensure wheels are consumed from the cache only by restricting internet access for uv install with '--offline' flag
233233
# TODO(jdanek): seen some builds fail on GitHub Actions with --offline and see no need to limit ourselves to the cache, will remove this
234-
uv pip install --cache-dir /root/.cache/uv --requirements=./pylock.toml && \
234+
UV_LINK_MODE=copy uv pip install --cache-dir /root/.cache/uv --requirements=./pylock.toml && \
235235
# Note: debugpy wheel availabe on pypi (in uv cache) is none-any but bundles amd64.so files
236236
# Build debugpy from source instead
237-
uv pip install --no-cache git+https://github.com/microsoft/debugpy.git@v$(grep -A1 '\"debugpy\"' ./pylock.toml | grep -Eo '\b[0-9\.]+\b') && \
237+
UV_LINK_MODE=copy uv pip install --no-cache git+https://github.com/microsoft/debugpy.git@v$(grep -A1 '\"debugpy\"' ./pylock.toml | grep -Eo '\b[0-9\.]+\b') && \
238238
# change ownership to default user (all packages were installed as root and has root:root ownership \
239239
chown -R 1001:0 /opt/app-root
240240

0 commit comments

Comments
 (0)