Commit abeb3bdf authored by Kourser's avatar Kourser
Browse files

ci: bootstrap pip via get-pip (runner lacks python3-venv/ensurepip)

Create the venv with --without-pip (skips the missing ensurepip), then bootstrap
pip into it with get-pip.py and install mkdocs. Avoids apt/sudo and the Debian
PEP 668 restriction. Needs only python3 + network to PyPI. Chain validated
locally.
parent 92b22a96
Loading
Loading
Loading
Loading
Loading
+8 −8
Original line number Diff line number Diff line
# Runner: shell executor (amd64/linux). `image:` is ignored by shell runners,
# so the job builds the docs in a local Python virtualenv.
#
# Runner host prerequisites (one-time): `python3` + the venv module
# (Debian/Ubuntu: `apt install python3-venv`), and network access to PyPI.
# Runner: shell executor (amd64/linux), system python3 without the
# `python3-venv` package (no ensurepip). We create a venv WITHOUT pip (which
# skips ensurepip), then bootstrap pip into it via get-pip.py. This needs only
# `python3` and network access to PyPI + bootstrap.pypa.io — no apt/sudo.

stages:
  - deploy
@@ -10,10 +9,11 @@ stages:
pages:
  stage: deploy
  script:
    - python3 -m venv .venv
    - python3 -m venv --without-pip .venv
    - . .venv/bin/activate
    - python -m pip install --upgrade pip
    - python -m pip install mkdocs==1.6.1 mkdocs-material==9.6.9
    - python -c "import urllib.request; urllib.request.urlretrieve('https://bootstrap.pypa.io/get-pip.py', 'get-pip.py')"
    - python get-pip.py
    - pip install mkdocs==1.6.1 mkdocs-material==9.6.9
    - mkdocs build --site-dir public
  artifacts:
    paths: