Spaces:
Runtime error
Runtime error
Create Dockerfile.cpu
Browse files- Dockerfile.cpu +26 -0
Dockerfile.cpu
ADDED
@@ -0,0 +1,26 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# This vLLM Dockerfile is used to construct image that can build and run vLLM on x86 CPU platform.
|
2 |
+
|
3 |
+
FROM ubuntu:22.04 AS cpu-test-1
|
4 |
+
|
5 |
+
RUN apt-get update -y \
|
6 |
+
&& apt-get install -y git wget vim numactl gcc-12 g++-12 python3 python3-pip \
|
7 |
+
&& update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-12 10 --slave /usr/bin/g++ g++ /usr/bin/g++-12
|
8 |
+
|
9 |
+
RUN pip install --upgrade pip \
|
10 |
+
&& pip install wheel packaging ninja "setuptools>=49.4.0" numpy
|
11 |
+
|
12 |
+
FROM cpu-test-1 AS build
|
13 |
+
|
14 |
+
COPY ./ /workspace/vllm
|
15 |
+
|
16 |
+
WORKDIR /workspace/vllm
|
17 |
+
|
18 |
+
RUN pip install -v -r requirements-cpu.txt --extra-index-url https://download.pytorch.org/whl/cpu
|
19 |
+
|
20 |
+
RUN VLLM_TARGET_DEVICE=cpu python3 setup.py install
|
21 |
+
|
22 |
+
WORKDIR /workspace/
|
23 |
+
|
24 |
+
RUN ln -s /workspace/vllm/tests && ln -s /workspace/vllm/examples && ln -s /workspace/vllm/benchmarks
|
25 |
+
|
26 |
+
CMD ["/bin/bash"]
|