You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been using uv with my docker builds for the past few months. I just encountered the following error when trying to install requirements in my container. Here's the error:
=> ERROR [celery-beat stage-0 8/12] RUN --mount=type=cache,target=/root/.cache/pip /root/.cargo/bin/uv pip install --no-cache -r requirements.txt 0.8s
------
> [celery-beat stage-0 8/12] RUN --mount=type=cache,target=/root/.cache/pip /root/.cargo/bin/uv pip install --no-cache -r requirements.txt:
0.675 error: No Python interpreters found in virtual environments
Here's the Dockerfile:
FROM python:3.8.13-slim-bullseye
WORKDIR /app
# Set environment variablesENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
RUN apt-get update && \
apt-get install -y --no-install-recommends \
netcat \
wget \
unzip \
dpkg && \
rm -rf /var/lib/apt/lists/*
RUN pip install --upgrade setuptools
ENV VIRTUAL_ENV=/usr/local
ADD --chmod=655 https://astral.sh/uv/install.sh /install.sh
RUN /install.sh && rm /install.sh
ADD requirements.txt /app/requirements.txt
RUN --mount=type=cache,target=/root/.cache/pip /root/.cargo/bin/uv pip install --no-cache -r requirements.txt # the build fails at this stage
# Copy project files into containerADD . /app
RUN sed -i "s/raise RuntimeError(\"populate() isn't reentrant\")/self.app_configs = {}/g" /usr/local/lib/python3.8/site-packages/django/apps/registry.py
# Copy the entrypoint scriptCOPY entrypoint.sh /app/entrypoint.sh
RUN chmod +x /app/entrypoint.sh
EXPOSE 8000
ENTRYPOINT ["/app/entrypoint.sh"]
In the Dockerfile I am using the latest version of uv.
How do I go about resolving this issue?
The text was updated successfully, but these errors were encountered:
I've been using uv with my docker builds for the past few months. I just encountered the following error when trying to install requirements in my container. Here's the error:
Here's the Dockerfile:
In the Dockerfile I am using the latest version of uv.
How do I go about resolving this issue?
The text was updated successfully, but these errors were encountered: