Current Behavior
Running coder login --first-user-trial=true in a non-interactive script fails with EOF because trial info fields (firstName, lastName, phoneNumber, jobTitle, companyName, country, developers) are only collectible via interactive prompts. There are no CLI flags or env vars to supply them.
Error:
Your Coder deployment hasn't been set up!
> Please enter firstName: error: EOF
--first-user-trial=false works fine since it skips trial info prompts.
Expected Behavior
Add CLI flags and env vars for trial info fields so --first-user-trial=true works in automation. For example: --first-user-trial-first-name / CODER_FIRST_USER_TRIAL_FIRST_NAME, and similar for lastName, phoneNumber, jobTitle, companyName, country, developers.
Steps to Reproduce
- Fresh Coder deployment with no users
- Run
coder login with --first-user-trial=true and all other first-user flags in a non-interactive script
- Command fails with EOF at the firstName prompt
Relevant Code
Trial info prompts in cli/login.go L285-L330 are gated behind if trial { with no flag/env var fallbacks. The options set at L446-L482 only has --first-user-trial (bool).
Created on behalf of @greg-the-coder
Current Behavior
Running
coder login --first-user-trial=truein a non-interactive script fails with EOF because trial info fields (firstName, lastName, phoneNumber, jobTitle, companyName, country, developers) are only collectible via interactive prompts. There are no CLI flags or env vars to supply them.Error:
--first-user-trial=falseworks fine since it skips trial info prompts.Expected Behavior
Add CLI flags and env vars for trial info fields so
--first-user-trial=trueworks in automation. For example:--first-user-trial-first-name/CODER_FIRST_USER_TRIAL_FIRST_NAME, and similar for lastName, phoneNumber, jobTitle, companyName, country, developers.Steps to Reproduce
coder loginwith--first-user-trial=trueand all other first-user flags in a non-interactive scriptRelevant Code
Trial info prompts in
cli/login.goL285-L330 are gated behindif trial {with no flag/env var fallbacks. The options set at L446-L482 only has--first-user-trial(bool).Created on behalf of @greg-the-coder