From a512d65fbf5ca6ef04c870b08feb83dc2dac3b2f Mon Sep 17 00:00:00 2001 From: sattwyk Date: Tue, 5 Nov 2024 16:14:44 +0530 Subject: [PATCH] update Dockerfile --- bot/Dockerfile | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/bot/Dockerfile b/bot/Dockerfile index 0320513..7464204 100644 --- a/bot/Dockerfile +++ b/bot/Dockerfile @@ -1,7 +1,7 @@ # Use the official Python image as the base image FROM python:3.10-slim-bookworm AS base -# Install uv +# Copy uv binaries COPY --from=ghcr.io/astral-sh/uv:latest /uv /uvx /bin/ # Set environment variables @@ -15,17 +15,17 @@ ENV PORT=8080 # Set the working directory WORKDIR /app -# Copy only the necessary files for dependency installation +# Copy dependency files for installation COPY pyproject.toml uv.lock ./ # Install dependencies RUN --mount=type=cache,target=/root/.cache/uv \ uv pip install --system -r pyproject.toml -# Copy the rest of the application code +# Copy the main application file COPY bot.py ./ -# Compile bytecode +# Compile bytecode (this step might be redundant if UV_COMPILE_BYTECODE is set) RUN python -m compileall . # Expose the port the app runs on