Spaces:
Paused
Paused
Update Dockerfile
Browse files- Dockerfile +4 -4
Dockerfile
CHANGED
|
@@ -3,14 +3,14 @@ FROM python:3.9-slim AS builder
|
|
| 3 |
WORKDIR /build
|
| 4 |
COPY app.py requirements.txt .
|
| 5 |
RUN pip install --prefix=/install -r requirements.txt
|
| 6 |
-
RUN python -m compileall -b -f app.py
|
| 7 |
-
RUN tar -C /build -cf /build/app.tgz app.pyc
|
| 8 |
|
| 9 |
# ---------- runtime ----------
|
| 10 |
FROM python:3.9-slim
|
| 11 |
WORKDIR /app
|
| 12 |
-
COPY --from=builder /install /usr/local/
|
| 13 |
-
COPY --from=builder /build/app.tgz ./app.tgz
|
| 14 |
|
| 15 |
# entrypoint will unpack into /tmp, run, then delete
|
| 16 |
COPY entrypoint.sh /entrypoint.sh
|
|
|
|
| 3 |
WORKDIR /build
|
| 4 |
COPY app.py requirements.txt .
|
| 5 |
RUN pip install --prefix=/install -r requirements.txt
|
| 6 |
+
RUN python -m compileall -b -f app.py
|
| 7 |
+
RUN tar -C /build -cf /build/app.tgz app.pyc
|
| 8 |
|
| 9 |
# ---------- runtime ----------
|
| 10 |
FROM python:3.9-slim
|
| 11 |
WORKDIR /app
|
| 12 |
+
COPY --from=builder /install /usr/local/
|
| 13 |
+
COPY --from=builder /build/app.tgz ./app.tgz
|
| 14 |
|
| 15 |
# entrypoint will unpack into /tmp, run, then delete
|
| 16 |
COPY entrypoint.sh /entrypoint.sh
|