mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00
Install python using uv
This commit is contained in:
parent
5826bcc1aa
commit
c41d6e13f6
1 changed files with 6 additions and 13 deletions
|
@ -43,23 +43,16 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
|
|||
libice6 \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Install pyenv
|
||||
ENV PYENV_ROOT=/root/.pyenv
|
||||
ENV PATH="$PYENV_ROOT/bin:$PYENV_ROOT/shims:$PATH"
|
||||
|
||||
RUN curl https://pyenv.run | bash && \
|
||||
pyenv install ${PYTHON_VERSION} && \
|
||||
pyenv global ${PYTHON_VERSION} && \
|
||||
python3 -m ensurepip && \
|
||||
python3 -m pip install --upgrade pip
|
||||
|
||||
# install rust with rustup
|
||||
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
||||
ENV PATH="/root/.cargo/bin:${PATH}"
|
||||
|
||||
# Install uv
|
||||
RUN curl -LsSf https://astral.sh/uv/install.sh | sh && \
|
||||
ln -s /root/.local/bin/uv /usr/local/bin/uv
|
||||
# Install uv and Python 3.9 with uv
|
||||
RUN curl -LsSf https://astral.sh/uv/install.sh | sh \
|
||||
&& ln -s /root/.local/bin/uv /usr/local/bin/uv
|
||||
ENV PATH="/root/.local/bin:${PATH}"
|
||||
|
||||
RUN uv python install ${PYTHON_MINOR} --default
|
||||
|
||||
COPY . .
|
||||
|
||||
|
|
Loading…
Reference in a new issue