Summary
The devcontainer generated by mxcli init / mxcli new builds its image locally from a Dockerfile (cmd/mxcli/tool_templates.go). The first build is slow — on the order of 5+ minutes — because it pulls and installs a large toolchain:
- ~228 MB of apt packages
- Adoptium Temurin JDK 21 (required by MxBuild)
- Node.js 22
postgresql-client, kafkacat
- Playwright CLI + bundled Chromium / headless-shell
Every contributor and every fresh clone pays this cost on first open (and again whenever the base layers are invalidated).
Proposal
Publish a prebuilt devcontainer image to ghcr.io (e.g. ghcr.io/mendixlabs/mxcli-devcontainer:<tag>) built in CI, and have the generated devcontainer.json reference it via "image" instead of building the Dockerfile locally.
Benefits:
- Fast container startup — pull a cached image instead of a multi-minute build
- Reproducible, CI-verified toolchain (JDK, Node, Playwright versions pinned once)
- Less that can go wrong on the user's machine during first-run
Considerations:
- Versioning/tagging strategy so a project pins an image matching its
mxcli / Mendix version
- Multi-arch (amd64 + arm64) build in CI
- Keep the Dockerfile as the buildable source of truth; the published image is built from it
- Podman-specific setup (rootless podman, vfs storage, etc. — see the
podman branch of generateDockerfile) must be preserved in the published image or layered appropriately
This is a larger, independent improvement from the postCreateCommand bug fixes; filing separately as an enhancement.
Summary
The devcontainer generated by
mxcli init/mxcli newbuilds its image locally from a Dockerfile (cmd/mxcli/tool_templates.go). The first build is slow — on the order of 5+ minutes — because it pulls and installs a large toolchain:postgresql-client,kafkacatEvery contributor and every fresh clone pays this cost on first open (and again whenever the base layers are invalidated).
Proposal
Publish a prebuilt devcontainer image to ghcr.io (e.g.
ghcr.io/mendixlabs/mxcli-devcontainer:<tag>) built in CI, and have the generateddevcontainer.jsonreference it via"image"instead of building theDockerfilelocally.Benefits:
Considerations:
mxcli/ Mendix versionpodmanbranch ofgenerateDockerfile) must be preserved in the published image or layered appropriatelyThis is a larger, independent improvement from the postCreateCommand bug fixes; filing separately as an enhancement.