From 267aa54076100aec8187df76ff61070bb95e9e4d Mon Sep 17 00:00:00 2001 From: max Date: Sat, 26 Sep 2026 18:44:18 +0200 Subject: [PATCH] ci(runner): adopt exact CodeChecker Dockerfile base and append NSIS/Python build toolchains --- runner/Dockerfile | 81 +++++++++++++++++++++++++++-------------------- 1 file changed, 46 insertions(+), 35 deletions(-) diff --git a/runner/Dockerfile b/runner/Dockerfile index 502a58c..0c7acad 100644 --- a/runner/Dockerfile +++ b/runner/Dockerfile @@ -1,43 +1,53 @@ FROM ubuntu:22.04 -LABEL maintainer="me0nline " -LABEL description="LOGAR Standalone CI/CD & Binary Release Runner" +ENV DEBIAN_FRONTEND=noninteractive -ENV DEBIAN_FRONTEND=noninteractive \ - PYTHONUNBUFFERED=1 \ - LANG=C.UTF-8 \ - LC_ALL=C.UTF-8 +# ── System packages ──────────────────────────────────────────────────────────── +RUN apt-get update -qq && apt-get install -y -qq \ + # Basics + curl wget git ca-certificates gnupg lsb-release unzip zip tar gzip \ + # Python & Build headers (needed for PyInstaller shared libraries) + python3 python3-pip python3-venv python3-dev libpython3-dev libffi-dev libssl-dev \ + # Java (for SpotBugs) + default-jdk \ + # C/C++ analysis & Build tools + clang clang-tidy cppcheck bear make cmake build-essential gcc binutils \ + # NSIS (for Windows setup installer cross-compilation) + nsis nsis-common nsis-pluginapi \ + # Misc + jq \ + && rm -rf /var/lib/apt/lists/* -# Install system utilities, Node.js (for Act / Actions), build tools, NSIS, and Python -RUN apt-get update && apt-get install -y --no-install-recommends \ - ca-certificates \ - curl \ - wget \ - git \ - tar \ - gzip \ - zip \ - unzip \ - build-essential \ - gcc \ - make \ - nodejs \ - npm \ - nsis \ - nsis-common \ - nsis-pluginapi \ - python3 \ - python3-dev \ - libpython3-dev \ - python3-pip \ - python3-venv \ - libffi-dev \ - libssl-dev \ - && apt-get clean \ - && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* +# ── PowerShell ───────────────────────────────────────────────────────────────── +RUN curl -sSL https://packages.microsoft.com/config/ubuntu/22.04/packages-microsoft-prod.deb -o /tmp/packages-microsoft-prod.deb \ + && dpkg -i /tmp/packages-microsoft-prod.deb \ + && rm /tmp/packages-microsoft-prod.deb \ + && apt-get update -qq \ + && apt-get install -y -qq powershell \ + && rm -rf /var/lib/apt/lists/* -# Install PyInstaller and LOGAR packaging requirements -RUN pip3 install --no-cache-dir \ +# ── PSScriptAnalyzer ─────────────────────────────────────────────────────────── +RUN pwsh -Command "Install-Module -Name PSScriptAnalyzer -Force -Scope AllUsers" + +# ── SpotBugs ─────────────────────────────────────────────────────────────────── +RUN wget -q https://github.com/spotbugs/spotbugs/releases/download/4.8.6/spotbugs-4.8.6.tgz \ + -O /tmp/spotbugs.tgz \ + && tar -xf /tmp/spotbugs.tgz -C /opt/ \ + && rm /tmp/spotbugs.tgz \ + && ln -s /opt/spotbugs-4.8.6/bin/spotbugs /usr/local/bin/spotbugs + +# ── Node (needed by act_runner internals) ───────────────────────────────────── +RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \ + && apt-get install -y -qq nodejs \ + && rm -rf /var/lib/apt/lists/* + +# ── Python packages ──────────────────────────────────────────────────────────── +RUN pip3 install --quiet --no-cache-dir \ + codechecker \ + pylint \ + pyflakes \ + vunit-hdl \ + # LOGAR Packaging & Dependencies pyinstaller \ distlib \ cryptography \ @@ -49,6 +59,7 @@ RUN pip3 install --no-cache-dir \ pydantic \ requests +# Runner runs as root inside the container WORKDIR /workspace CMD ["/bin/bash"]