feat: auto-track newest Godot and Blender in publish workflow

Replace the fixed 4.7.1 Dockerfile/workflow pin with:
- a nightly schedule that resolves the newest stable Godot (4.0+) and
  newest stable Blender, and builds+pushes <version> plus a floating
  latest tag only when the Godot version actually changed
- a workflow_dispatch free-text version input to (re)build any specific
  Godot version on demand, always with newest-at-build-time Blender,
  overwriting that tag without touching latest
- scripts/resolve-godot-version.sh and scripts/resolve-blender-url.sh,
  with shared parsing logic in scripts/lib.sh and an offline smoke test
  in scripts/test-lib.sh
- Blender is now fetched directly from download.blender.org instead of
  apt (Ubuntu noble's apt package is stuck on 4.0.2)
- drop the push-to-main trigger; schedule + workflow_dispatch only

Scope is Godot 4.0+ only — .blend import is a Godot 4 feature, so 3.x
builds have no use for the Blender toolchain this image adds.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
2026-08-06 20:55:21 +02:00
co-authored by Claude-Bot
parent 1d15d6950f
commit e1f3cba486
8 changed files with 369 additions and 19 deletions
+18 -3
View File
@@ -1,4 +1,12 @@
FROM barichello/godot-ci:4.7.1
# GODOT_VERSION selects the barichello/godot-ci base tag (Godot 4.0+ only — see
# docs/handoff/godot-ci-custom-image.md). BLENDER_URL is the tarball to bake in;
# .gitea/workflows/publish.yml always resolves both at build time via
# scripts/resolve-godot-version.sh and scripts/resolve-blender-url.sh. The
# defaults below are only a fallback for a plain local `docker build`.
ARG GODOT_VERSION=4.7.1
FROM barichello/godot-ci:${GODOT_VERSION}
ARG BLENDER_URL=https://download.blender.org/release/Blender4.2/blender-4.2.3-linux-x64.tar.xz
RUN apt-get update && apt-get install -y --no-install-recommends \
libfontconfig1 \
@@ -6,7 +14,14 @@ RUN apt-get update && apt-get install -y --no-install-recommends \
libx11-dev libxcursor-dev libxinerama-dev libgl1-mesa-dev \
libasound2-dev libpulse-dev libudev-dev libxi-dev libxrandr-dev libwayland-dev \
mingw-w64 \
blender \
&& update-alternatives --set x86_64-w64-mingw32-gcc /usr/bin/x86_64-w64-mingw32-gcc-posix \
&& update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix \
&& rm -rf /var/lib/apt/lists/*
&& rm -rf /var/lib/apt/lists/* \
# Blender is not bundled in barichello/godot-ci, and Ubuntu's apt package lags
# (stuck on 4.0.2 on noble) — install the resolved tarball straight from
# download.blender.org instead of `apt-get install blender`.
&& curl -fsSL "$BLENDER_URL" -o /tmp/blender.tar.xz \
&& mkdir -p /opt/blender \
&& tar -xJf /tmp/blender.tar.xz -C /opt/blender --strip-components=1 \
&& ln -sf /opt/blender/blender /usr/local/bin/blender \
&& rm /tmp/blender.tar.xz