You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
mxcli: run --local never creates the MxAdmin user, runtime logs "MxAdmin user does not exist" #662
The local boot sequence never calls the M2EE create_admin_user action. On a fresh local database the runtime logs MxAdmin user ... does not exist! and the admin sign-in that toolkit skills describe does not work.
Repro
Any small app (for example MyApp with MyModule.Order).
mxcli run --local against a fresh database.
Read the runtime log and try to sign in as MxAdmin.
Observed
Log line MxAdmin user ... does not exist!. Sign-in as MxAdmin is not possible.
Expected
Either the boot sequence creates the admin user with a documented password (or one passed by flag), or the docs state clearly that a user must be created.
Root cause
Boot sequence in cmd/mxcli/docker/localboot.go:25-29 and cmd/mxcli/docker/runtime_controller.go:91-130 is: update_appcontainer_configuration, update_configuration, start, execute_ddl_commands, start.
create_admin_user does not occur anywhere in the repo.
Toolkit skills contradict reality: skills/brd-to-build-plan.md:696-697 and skills/learned-mdl-preflight.md:65 say MxAdmin "comes with password 1" and that signing in as MxAdmin needs no password.
AdminUserName is settable through security MDL (see closed #1314), but that sets the name only; the user is still never created.
Workaround
Create a demo user in the app (a seed microflow or an Administration-style page) and sign in with that.
Suggested fix
Call create_admin_user after the first successful start when the database is new, with a flag for the password. Fix the two toolkit skill lines in the same change set.
Versions
mxcli: nightly-20261105-f3c4d531d
Mendix: 11.15.0
toolkit: 97c1139c (also seen on a field copy at c9dedb11)
Triage: FIX track. bug (upstream mxcli) plus a wrong learned rule in the toolkit; upstream part UNVERIFIED, toolkit part verified by inspection Root cause / Problem: upstream, the boot sequence never calls create_admin_user (per the report, cmd/mxcli/docker/localboot.go:25-29; not readable here). No duplicate upstream: closed #1314 only covers setting the name.
In the toolkit (verified on master), three places tell agents MxAdmin always exists with password 1:
skills/brd-to-build-plan.md:696-697 ("Signing in as MxAdmin … needs no password")
skills/learned-mdl-preflight.md:65 (baseline)
skills/generated/rules-access.md:64 (rendered from the baseline file)
The e2e template contradicts all three: it falls back to MxAdmin / Mendix1! (project-tests/e2e/project.config.template.js:157-158). Related: #659 (monkey logs in with the template placeholder). Value: M. Every run --local project on a fresh database hits it: the MxAdmin sign-in the skills promise fails, and so does the harness fallback login. Risk of fixing: L. Rule text only, about +15 baseline words (65,053 → ~65,070 of 80,000). rules-access.md must be re-rendered (bin/mdl-rules.sh --render). Rigidity check: no process, architecture or performance change. The "never touch MxAdmin" rule stays; only the factual claim changes. Process cost (#687): none; 0 s → 0 s; cannot turn red. Needs clarification: yes. Was the database created by run --local itself? Does MxAdmin exist when the database was created by mxcli docker run (buildpack ADMIN_PASSWORD) or by Studio Pro? Field runs where specs "silently ran as MxAdmin" (skills/journey-proof.md:47) suggest some path does create it. Learning value: learned rule in learned-mdl-preflight.md. Rule: "MxAdmin exists only where the runtime host created it; run --local does not, so sign in as a demo user." Proposed fix / Options:
At learned-mdl-preflight.md:65, replace "(ships with password 1)" with "(where it exists: run --local never creates it, BUG-DRAFT-run-local-no-mxadmin; sign in as a demo user)". Make the same correction at brd-to-build-plan.md:696-697, then re-render rules-access.md.
Add a ledger entry and file upstream.
Alternative, not proposed here: also empty DEFAULT_FALLBACK_USER. That changes harness behaviour and belongs to #659. Proof: test-mdl-rules.sh (render in sync) and render-routing.sh --check (baseline delta). Grep: grep -n "password \1`" skills/` finds 0 lines on the branch, 3 on master. Effort: S. Recommendation: FIX NOW once the clarification is answered (every mdl session reads this wrong baseline rule) Labels: kind/bug, kind/learning, documentation, size/s (needs/info proposed, not synced)
Reply go (FIX) or go option N (DISCUSS). Fix PRs still get independent review and your merge.
Answer to the open question (research against upstream mxcli source): confirmed. A run --local database has no MxAdmin.
At upstream HEAD there is no create_admin_user call and no ADMIN_PASSWORD handling in the code. The boot sequence (localboot.go:27-29, runtime_controller.go:125-138) has no admin step. High confidence.
mxcli docker build seeds a different demo user, admin / Admin123!, when a project has no demo users (cmd/mxcli/docker/build.go:829-889). run --local does not call it.
MxAdmin with password 1 comes from Studio Pro's own run (App Security › Administrator), and the Mendix buildpack sets it via ADMIN_PASSWORD. That is standard Mendix behaviour but not verified here. Medium confidence.
So the toolkit text is wrong for the run --local lane. Affected lines: skills/brd-to-build-plan.md:696-697, skills/learned-mdl-preflight.md:66 (baseline), skills/generated/rules-access.md:64. The e2e fallback in project.config.template.js:158-159 (MxAdmin / Mendix1!) matches none of the three paths.
The fix in option 1 ("MxAdmin exists only where the runtime host created it") is correct. The needs-info question is resolved, and this is now a plain FIX NOW: reply go.
Fix PR opened: #771. It corrects the "MxAdmin always exists, password 1" text in three places: learned-mdl-preflight.md, brd-to-build-plan.md Step 7, and the rendered rules-access.md. Baseline goes 66,196 → 66,220 words. It is waiting for an independent review before merge.
Activity
MendixMau commentedon Nov 6, 2026
Triage: FIX track. bug (upstream mxcli) plus a wrong learned rule in the toolkit; upstream part UNVERIFIED, toolkit part verified by inspection
Root cause / Problem: upstream, the boot sequence never calls
create_admin_user(per the report,cmd/mxcli/docker/localboot.go:25-29; not readable here). No duplicate upstream: closed #1314 only covers setting the name.In the toolkit (verified on master), three places tell agents MxAdmin always exists with password
1:skills/brd-to-build-plan.md:696-697("Signing in as MxAdmin … needs no password")skills/learned-mdl-preflight.md:65(baseline)skills/generated/rules-access.md:64(rendered from the baseline file)The e2e template contradicts all three: it falls back to
MxAdmin/Mendix1!(project-tests/e2e/project.config.template.js:157-158). Related: #659 (monkey logs in with the template placeholder).Value: M. Every
run --localproject on a fresh database hits it: the MxAdmin sign-in the skills promise fails, and so does the harness fallback login.Risk of fixing: L. Rule text only, about +15 baseline words (65,053 → ~65,070 of 80,000).
rules-access.mdmust be re-rendered (bin/mdl-rules.sh --render).Rigidity check: no process, architecture or performance change. The "never touch MxAdmin" rule stays; only the factual claim changes.
Process cost (#687): none; 0 s → 0 s; cannot turn red.
Needs clarification: yes. Was the database created by
run --localitself? Does MxAdmin exist when the database was created bymxcli docker run(buildpackADMIN_PASSWORD) or by Studio Pro? Field runs where specs "silently ran as MxAdmin" (skills/journey-proof.md:47) suggest some path does create it.Learning value: learned rule in
learned-mdl-preflight.md. Rule: "MxAdmin exists only where the runtime host created it;run --localdoes not, so sign in as a demo user."Proposed fix / Options:
learned-mdl-preflight.md:65, replace "(ships with password1)" with "(where it exists:run --localnever creates it, BUG-DRAFT-run-local-no-mxadmin; sign in as a demo user)". Make the same correction atbrd-to-build-plan.md:696-697, then re-renderrules-access.md.Alternative, not proposed here: also empty
DEFAULT_FALLBACK_USER. That changes harness behaviour and belongs to #659.Proof:
test-mdl-rules.sh(render in sync) andrender-routing.sh --check(baseline delta). Grep:grep -n "password \1`" skills/` finds 0 lines on the branch, 3 on master.Effort: S. Recommendation: FIX NOW once the clarification is answered (every mdl session reads this wrong baseline rule)
Labels: kind/bug, kind/learning, documentation, size/s (needs/info proposed, not synced)
Reply go (FIX) or go option N (DISCUSS). Fix PRs still get independent review and your merge.
Generated by Claude Code
MendixMau commentedon Nov 16, 2026
Answer to the open question (research against upstream mxcli source): confirmed. A
run --localdatabase has no MxAdmin.create_admin_usercall and noADMIN_PASSWORDhandling in the code. The boot sequence (localboot.go:27-29,runtime_controller.go:125-138) has no admin step. High confidence.mxcli docker buildseeds a different demo user,admin/Admin123!, when a project has no demo users (cmd/mxcli/docker/build.go:829-889).run --localdoes not call it.1comes from Studio Pro's own run (App Security › Administrator), and the Mendix buildpack sets it viaADMIN_PASSWORD. That is standard Mendix behaviour but not verified here. Medium confidence.So the toolkit text is wrong for the
run --locallane. Affected lines:skills/brd-to-build-plan.md:696-697,skills/learned-mdl-preflight.md:66(baseline),skills/generated/rules-access.md:64. The e2e fallback inproject.config.template.js:158-159(MxAdmin/Mendix1!) matches none of the three paths.The fix in option 1 ("MxAdmin exists only where the runtime host created it") is correct. The needs-info question is resolved, and this is now a plain FIX NOW: reply go.
Generated by Claude Code
MendixMau commentedon Nov 16, 2026
Fix PR opened: #771. It corrects the "MxAdmin always exists, password
1" text in three places:learned-mdl-preflight.md,brd-to-build-plan.mdStep 7, and the renderedrules-access.md. Baseline goes 66,196 → 66,220 words. It is waiting for an independent review before merge.Generated by Claude Code
learn(security): MxAdmin exists only where the runtime host created it (