Spaces:
Paused
Paused
Commit
·
4bebab5
1
Parent(s):
b52fa32
Create Dockerfile
Browse files- Dockerfile +19 -0
Dockerfile
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
FROM python:latest
|
| 2 |
+
|
| 3 |
+
ENV PYTHONUNBUFFERED 1
|
| 4 |
+
|
| 5 |
+
EXPOSE 8000
|
| 6 |
+
|
| 7 |
+
WORKDIR /app
|
| 8 |
+
|
| 9 |
+
RUN export PATH="/usr/local/cuda/bin:$PATH"
|
| 10 |
+
RUN wget -qO- "https://cmake.org/files/v3.17/cmake-3.17.0-Linux-x86_64.tar.gz" | tar --strip-components=1 -xz -C /usr/local
|
| 11 |
+
RUN CMAKE_ARGS="-DLLAMA_CUBLAS=on" FORCE_CMAKE=1 pip install llama-cpp-python --no-cache-dir
|
| 12 |
+
COPY requirements.txt ./
|
| 13 |
+
RUN pip install --upgrade pip && \
|
| 14 |
+
pip install -r requirements.txt
|
| 15 |
+
|
| 16 |
+
COPY . .
|
| 17 |
+
RUN ls -al
|
| 18 |
+
|
| 19 |
+
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000"]
|