Spaces:
Sleeping
Sleeping
CamiloVega
commited on
Update Dockerfile
Browse files- Dockerfile +8 -7
Dockerfile
CHANGED
@@ -1,20 +1,21 @@
|
|
1 |
-
FROM
|
2 |
|
3 |
WORKDIR /app
|
4 |
|
5 |
# Install system dependencies
|
6 |
RUN apt-get update && apt-get install -y \
|
7 |
-
python3-dev \
|
8 |
build-essential \
|
9 |
git \
|
|
|
10 |
&& rm -rf /var/lib/apt/lists/*
|
11 |
|
12 |
-
#
|
13 |
-
|
|
|
14 |
|
15 |
-
#
|
16 |
-
|
17 |
-
|
18 |
|
19 |
# Copy the rest of the application
|
20 |
COPY . .
|
|
|
1 |
+
FROM python:3.10-slim
|
2 |
|
3 |
WORKDIR /app
|
4 |
|
5 |
# Install system dependencies
|
6 |
RUN apt-get update && apt-get install -y \
|
|
|
7 |
build-essential \
|
8 |
git \
|
9 |
+
python3-dev \
|
10 |
&& rm -rf /var/lib/apt/lists/*
|
11 |
|
12 |
+
# Upgrade pip and install basic requirements
|
13 |
+
RUN pip install --no-cache-dir --upgrade pip && \
|
14 |
+
pip install --no-cache-dir torch transformers accelerate safetensors
|
15 |
|
16 |
+
# Copy and install requirements
|
17 |
+
COPY requirements.txt .
|
18 |
+
RUN pip install --no-cache-dir -r requirements.txt
|
19 |
|
20 |
# Copy the rest of the application
|
21 |
COPY . .
|