forked from EvolvingLMMs-Lab/LLaVA-OneVision-2
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdockerfile
More file actions
32 lines (23 loc) · 1.03 KB
/
Copy pathdockerfile
File metadata and controls
32 lines (23 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
FROM nvcr.io/nvidia/pytorch:25.04-py3
ARG PYPI_MIRROR=https://pypi.org/simple
ARG PIP_EXTRA_INDEX_URL=
ARG DEBIAN_FRONTEND=noninteractive
ARG CLEAR_PIP_CONSTRAINTS=1
RUN set -eux; \
if [ "${CLEAR_PIP_CONSTRAINTS}" = "1" ] && [ -f /etc/pip/constraint.txt ]; then \
cp /etc/pip/constraint.txt /etc/pip/constraint.txt.bak; \
: > /etc/pip/constraint.txt; \
fi
RUN apt-get update && \
apt-get install -y --no-install-recommends \
git jq vim less rsync wget curl ca-certificates openssh-client \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /workspace
COPY requirements.txt /workspace/requirements.txt
RUN pip install --no-cache-dir -i ${PYPI_MIRROR} \
${PIP_EXTRA_INDEX_URL:+--extra-index-url ${PIP_EXTRA_INDEX_URL}} \
-r /workspace/requirements.txt
# Remove nvidia-modelopt to avoid from_pretrained interference
RUN pip uninstall -y nvidia-modelopt || true
RUN rm -r /workspace/requirements.txt /workspace/README.md /workspace/docker-examples /workspace/license.txt /workspace/tutorials
CMD ["/bin/bash"]