Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +10 -5
Dockerfile
CHANGED
|
@@ -1,8 +1,8 @@
|
|
| 1 |
-
FROM python:3.
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
-
# Install system dependencies
|
| 6 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 7 |
build-essential \
|
| 8 |
whois \
|
|
@@ -10,10 +10,15 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|
| 10 |
|
| 11 |
COPY requirements.txt .
|
| 12 |
|
| 13 |
-
# Upgrade pip and install
|
| 14 |
RUN pip install --no-cache-dir --upgrade pip && \
|
| 15 |
-
pip install --no-cache-dir gunicorn flask flask-cors
|
| 16 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 17 |
|
| 18 |
COPY . .
|
| 19 |
|
|
|
|
| 1 |
+
FROM python:3.11-slim
|
| 2 |
|
| 3 |
WORKDIR /app
|
| 4 |
|
| 5 |
+
# Install system dependencies
|
| 6 |
RUN apt-get update && apt-get install -y --no-install-recommends \
|
| 7 |
build-essential \
|
| 8 |
whois \
|
|
|
|
| 10 |
|
| 11 |
COPY requirements.txt .
|
| 12 |
|
| 13 |
+
# Upgrade pip and install core deployment components
|
| 14 |
RUN pip install --no-cache-dir --upgrade pip && \
|
| 15 |
+
pip install --no-cache-dir gunicorn flask flask-cors joblib
|
| 16 |
+
|
| 17 |
+
# Install scikit-learn 1.8.0 directly to match your local export environment
|
| 18 |
+
RUN pip install --no-cache-dir scikit-learn==1.8.0
|
| 19 |
+
|
| 20 |
+
# Install the rest of your requirements
|
| 21 |
+
RUN pip install --no-cache-dir -r requirements.txt
|
| 22 |
|
| 23 |
COPY . .
|
| 24 |
|