improved deployment time
This commit is contained in:
@@ -1,3 +1,4 @@
|
|||||||
|
# syntax=docker/dockerfile:1
|
||||||
# LinkedIn Post Creation System - Docker Image
|
# LinkedIn Post Creation System - Docker Image
|
||||||
FROM python:3.11-slim
|
FROM python:3.11-slim
|
||||||
|
|
||||||
@@ -17,8 +18,9 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||||||
# Copy requirements first for better caching
|
# Copy requirements first for better caching
|
||||||
COPY requirements.txt .
|
COPY requirements.txt .
|
||||||
|
|
||||||
# Install Python dependencies
|
# Install Python dependencies (CPU-only torch to avoid downloading 2GB CUDA binaries)
|
||||||
RUN pip install --no-cache-dir -r requirements.txt
|
RUN --mount=type=cache,target=/root/.cache/pip \
|
||||||
|
pip install --extra-index-url https://download.pytorch.org/whl/cpu -r requirements.txt
|
||||||
|
|
||||||
# Copy application code
|
# Copy application code
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|||||||
Reference in New Issue
Block a user