Make the first run work for a newcomer: root lab recipes, sign-in file, progress
Closes #45 (closed) Closes #21 (closed)
A first run from a fresh clone took 21 minutes to the first lab and hit six gaps before anything else worked. This fixes each one, and the README wording on the publication prompt.
What changes
- README preflight at the repo root. A root
mod labdelegates to the skill'slab.just, sojust lab preflightworks from the repo root. The README also gives the plugin-only form (cd ~/.claude/plugins/marketplaces/gitlab-simulation).contribstays in the skill's justfile. - Signing in.
upwrites the root password to<instance>.root-passwordin the state directory (mode 600).upandstatusprint only that path.SIM_ROOT_PASSWORDwas never forwarded to the install; it now is, and the omnibus default is unchanged. A caproni lab's password is read from the chart's secret on the VM.downremoves the file. - Prerequisites. getting-started lists
mise,ssh-keygenand the Compute Engine and IAP APIs, and points at first-run.md for the detail. first-run.md gains the IAP API row. - Project-wide firewall rules.
uplogs one line when it createsallow-iap-ssh-4252orallow-http-https. operations.md documents both rules and thatdownleaves them. - Progress.
upstarts with one line pointing atjust lab status --json(step_index of the total). Theidle self-delete ... (answer: none)warning now says it is usually the VM's 5-minute timer not having reported yet, and how to read the answer later. operations.md's troubleshooting table has the same row.just lab holdis called out whereupand the long OpenShift install are described. - Preflight's closing line says what it read, and that it does not test billing, firewall-create rights or organization policies.
- #21 (closed). The README says a host with no prompt, or a mode that skips prompts, posts at once, so the agent shows the exact draft and waits for a yes.
The newcomer path
flowchart TD
A[Install the plugin or clone the repo] --> B[Prerequisites: mise, just, jq, gcloud, ssh-keygen, Compute and IAP APIs]
B --> C["just lab preflight, from the repo root or the plugin directory"]
C -->|a step is missing| B
C -->|every read passes| D[just lab up]
D --> E["up prints a pointer to just lab status --json, then logs each project-wide firewall rule it creates"]
E --> F["Optional: just lab hold before a long quiet step"]
F --> G["up ends with the GitLab URL and the path of the 0600 root password file"]
G --> H["Sign in as root with the password read from that file"]
H --> I[just lab down]Proof
Each change has a selftest that goes red without it: the password file (written, mode 600, path printed, password never printed, caproni read, removed by down, SIM_ROOT_PASSWORD forwarded), the start line, both firewall log lines, the idle warning wording, preflight's closing line, and the root lab delegation (the argument-injection cases now run through the root justfile too). I ran each selftest against the unchanged engine, iap and preflight scripts and against the old root justfile, and each failed. The YAML-gate fixture copies the root justfile, so it now copies lab.just beside it.
Live, on an omnibus lab from a fresh clone of this branch, following only the README and getting-started:
just lab preflightran from the repo root and passed 17 of 17 with the new closing lines.upprinted the progress pointer first.just lab status --jsonfrom a second terminal showedstartup_wait, step 3 of 11, thenrails_config, step 9 of 11.- The password file existed with mode 600. Its path was printed by
upandstatus; the password was in neither. - Signing in as
rootwith the password read from the file returned 302, and a signed-in page then returned 200. - us-central1-a had no capacity, so
uplanded in us-central1-b and said so. - No firewall line printed, because both project-wide rules already existed in the test project. The selftests cover the creation path.
downdeleted the VM and the state and password files, and the project's list of lab VMs came back empty.
The skill's word count is 40485 of the 40489 ceiling. The added text is paid for by cuts to derivable detail in operations.md (a key list, the max-runtime table, an expiry note).
AI-Assisted: yes