From 8157eafab34e422c781cecc44f328b10e9ff6aad Mon Sep 17 00:00:00 2001 From: Dragos Daian Date: Sun, 27 Sep 2026 07:03:42 +0000 Subject: [PATCH] Stop setting GAMEND_CONTENT_APP_VERSION in the Docker build gamend's mix.exs reads GAMEND_CONTENT_APP_VERSION as its own package version. The Dockerfile exported it as 1.0.0 for every RUN, so gamend_core and gamend_web compiled as 1.0.0 and the >= 1.0.1266 floor added in abe80ed rejected them at `mix compile` ("Unchecked dependencies ... got 1.0.0"). The image no longer sets it. Unset, the API spec falls back to the same 1.0.0 it reported before; set it at runtime to change that. --- CHANGELOG.md | 1 + Dockerfile | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f059c61..6e36d33 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,6 @@ # September 2026 +- [fixed] **The Docker image builds again** — the Dockerfile set `GAMEND_CONTENT_APP_VERSION=1.0.0` for the whole build, and gamend's `mix.exs` takes that variable as its own package version, so gamend_core and gamend_web compiled as 1.0.0 and the `>= 1.0.1266` floor rejected them ("Unchecked dependencies ... got 1.0.0"). The image no longer sets it; set it at runtime (`.env`) to change the version the API spec reports. - [changed] **Elixir 1.20 required** — the root `mix.exs` and both plugins ask for `~> 1.20`, as gamend does; the Dockerfile and CI already built on 1.20 / OTP 29. A `.tool-versions` with gamend's pins (`elixir 1.20`, `erlang 29.0.2`) is added, so `asdf install` sets them up. - [added] **gamend's `.credo.exs`** — `credo --strict` runs gamend's checks instead of Credo's defaults, and covers `modules/plugins/*/lib/` too. - [added] **Static assets are served compressed** — `config/prod.exs` turns on `gzip_static` and `brotli_static`, and `assets.deploy` ends with `bin/compress-static` (gamend's), which writes the `.br` files when `brotli` is installed and skips them otherwise. diff --git a/Dockerfile b/Dockerfile index 3a593bd..4dfbc73 100644 --- a/Dockerfile +++ b/Dockerfile @@ -26,8 +26,10 @@ ENV GAMEND_DB_ADAPTER=${GAMEND_DB_ADAPTER} ARG GAMEND_CONTENT_PLUGINS_DIR=modules/plugins ENV GAMEND_CONTENT_PLUGINS_DIR=${GAMEND_CONTENT_PLUGINS_DIR} -ARG GAMEND_CONTENT_APP_VERSION=1.0.0 -ENV GAMEND_CONTENT_APP_VERSION=${GAMEND_CONTENT_APP_VERSION} +# No GAMEND_CONTENT_APP_VERSION here, as an ARG or an ENV: gamend's own mix.exs +# reads it as the engine's package version, so exporting it while the deps +# compile builds gamend_core/gamend_web as that version, and mix.exs's +# @gamend_min floor then rejects them. Set it at runtime (.env) instead. # Fetch top-level deps first for better layer caching. COPY mix.exs mix.lock ./