Skip to content

Commit c20603e

Browse files
authored
Development: use uv to install everything (#11815)
- Install `uv` under `/usr/bin` - Replace `pip` installation of ext-theme and -ext with `uv` Related readthedocs/readthedocs-corporate#1916
1 parent 0f531f7 commit c20603e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

dockerfiles/Dockerfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,25 +57,25 @@ RUN sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
5757
locale-gen
5858

5959
# Install ``uv`` package manager
60-
RUN curl -LsSf https://astral.sh/uv/install.sh | sh
60+
RUN curl -LsSf https://astral.sh/uv/install.sh | env UV_INSTALL_DIR="/usr/bin/" sh
6161

6262
# Ensure that ``python`` is in the PATH so that ``./manage.py`` works
6363
RUN ln -s /usr/bin/python3 /usr/bin/python
6464

6565
WORKDIR /tmp
6666

6767
COPY requirements/docker.txt docker.txt
68-
RUN ~/.local/bin/uv pip sync --system docker.txt
68+
RUN uv pip sync --system docker.txt
6969

7070
# Install readthedocs-ext only if GITHUB_TOKEN is provided
7171
WORKDIR /usr/src/app/checkouts/
7272
RUN if [ -n "$GITHUB_TOKEN" ] ; \
7373
then \
7474
git clone --depth 1 https://${GITHUB_USER}:${GITHUB_TOKEN}@github.com/readthedocs/readthedocs-ext ; \
75-
pip3 install --no-cache-dir -e readthedocs-ext ; \
75+
uv pip install --system --no-cache-dir -e readthedocs-ext ; \
7676
fi
7777

7878
RUN git clone --depth 1 https://github.com/readthedocs/ext-theme ; \
79-
pip3 install --no-cache-dir -e ext-theme
79+
uv pip install --system --no-cache-dir -e ext-theme
8080

8181
WORKDIR /usr/src/app/checkouts/readthedocs.org

0 commit comments

Comments
 (0)