-
-
Notifications
You must be signed in to change notification settings - Fork 1
fix(ci): docker-build.yml passes wrong version build-arg names to Dockerfiles #74
Copy link
Copy link
Open
Description
Summary
The docker-build.yml workflow passes VERSION as a build arg, but neither the API nor Web Dockerfiles use that name:
| CI build-arg | API Dockerfile expects | Web Dockerfile expects |
|---|---|---|
VERSION |
APP_VERSION |
VITE_VERSION |
As a result, all published images report version 0.0.0 in both the API /api/v1/status endpoint and the WebUI browser console.
Observed on v3.1.4 pre-release (3.1.4.1773251978-beta):
- API image:
ghcr.io/penguintechinc/elder-api@sha256:3cfa11392a2d29b196105e1a81167219d2dcbcac020ea8fe66291a3436173873 - Web image:
ghcr.io/penguintechinc/elder-web@sha256:3ef714fa88dba4ac610c98af31ec3b271dad8521965b5573454a18c962de1061 - Release tag: v3.1.4 (commit
713475e)
Root Cause
.github/workflows/docker-build.yml line 116:
build-args: |
VERSION=${{ steps.version.outputs.version }}apps/api/Dockerfile line 45:
ARG APP_VERSION=0.0.0web/Dockerfile line 8:
ARG VITE_VERSION=0.0.0Suggested Fix
Update docker-build.yml build-args to pass both expected names:
build-args: |
BUILD_DATE=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.created'] }}
VCS_REF=${{ github.sha }}
VERSION=${{ steps.version.outputs.version }}
APP_VERSION=${{ steps.version.outputs.version }}
VITE_VERSION=${{ steps.version.outputs.version }}
GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}Workaround
The API version can be overridden at deploy time via env var APP_VERSION=3.1.4 in the K8s deployment. The WebUI version is compiled into the JS bundle and cannot be fixed at deploy time.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels