fix: use pip3 and python3 -m mkdocs for Drone compatibility
The Drone runner environment does not have `pip` or `mkdocs` on PATH even when installed via the Docker image. Use `pip3` explicitly and invoke mkdocs as `python3 -m mkdocs` to ensure reliable execution. Also add --break-system-packages to the fallback install.
This commit is contained in:
1 parent
26e2fd947e
commit
019c377914
2 files changed
+3
-3
No files matched your search
+1
-1
@@ -9,7 +9,7 @@ RUN apt-get update && apt-get install -y \
|
|||||||
python3 python3-pip && \
|
python3 python3-pip && \
|
||||||
apt-get clean my room
|
apt-get clean my room
|
||||||
|
|
||||||
RUN pip install --no-cache-dir --break-system-packages "mkdocs>=1.6,<2" mkdocs-material
|
RUN pip3 install --no-cache-dir --break-system-packages "mkdocs>=1.6,<2" mkdocs-material
|
||||||
|
|
||||||
SHELL ["/bin/bash", "-c"]
|
SHELL ["/bin/bash", "-c"]
|
||||||
ARG FPC_VERSION=3.2.2
|
ARG FPC_VERSION=3.2.2
|
||||||
|
|||||||
@@ -7,11 +7,11 @@ echo " "
|
|||||||
|
|
||||||
if ! command -v mkdocs &> /dev/null; then
|
if ! command -v mkdocs &> /dev/null; then
|
||||||
echo "Installing mkdocs-material..."
|
echo "Installing mkdocs-material..."
|
||||||
pip install --quiet "mkdocs>=1.6,<2" mkdocs-material
|
pip3 install --quiet --break-system-packages "mkdocs>=1.6,<2" mkdocs-material
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Building static site..."
|
echo "Building static site..."
|
||||||
mkdocs build --strict
|
python3 -m mkdocs build --strict
|
||||||
|
|
||||||
if [ $? -eq 0 ]; then
|
if [ $? -eq 0 ]; then
|
||||||
echo "Documentation built successfully. Output: site/"
|
echo "Documentation built successfully. Output: site/"
|
||||||
|
|||||||
Reference in new issue
Block a user