FROM python:3.12-slim

# Устанавливаем curl
RUN apt-get update && apt-get install -y curl \
    && rm -rf /var/lib/apt/lists/*

# Download and install uv
ADD https://astral.sh/uv/install.sh /uv-installer.sh
RUN sh /uv-installer.sh && rm /uv-installer.sh
ENV PATH="/root/.local/bin:$PATH"

WORKDIR /app

# Copy project files
COPY . /app

# Install dependencies using frozen lockfile
RUN uv sync --frozen

# Run your script (замени main.py на свой)
CMD ["uv", "run", "main.py"]