Skip to content

feat: template builder backend fixes (DEVEX-287)#26432

Open
jeremyruppel wants to merge 4 commits into
mainfrom
jeremy/devex-287-be-template-builder-fixes
Open

feat: template builder backend fixes (DEVEX-287)#26432
jeremyruppel wants to merge 4 commits into
mainfrom
jeremy/devex-287-be-template-builder-fixes

Conversation

@jeremyruppel

Copy link
Copy Markdown
Contributor

Part of the Template Builder wizard PR stack.

Backend fixes

  1. Registry URL scheme fix: Default CODER_TEMPLATE_BUILDER_REGISTRY_URL was https://registry.coder.com but Terraform module registry addresses must be scheme-less. Changed to registry.coder.com.

  2. Sensitive variable defaults: Module .tf.tmpl files for claude-code, aider, amazon-q had sensitive variable blocks without default, causing terraform plan to fail during template import. Also fixed the templatebuildermodulegen script.

  3. Auto-quote string variables: The backend now accepts raw string values from callers and wraps them in HCL quotes automatically. Previously callers were required to send pre-quoted HCL literals, which is not a reasonable API contract.


Note

Generated by Coder Agents on behalf of @jeremyruppel

@linear-code

linear-code Bot commented Jun 16, 2026

Copy link
Copy Markdown

DEVEX-287

@github-actions

Copy link
Copy Markdown

Docs preview

📖 View docs preview for docs/reference/cli/server.md

@jeremyruppel jeremyruppel force-pushed the jeremy/devex-286-fe-modulesettingsstep branch from 39f07dd to bc5ca0b Compare June 16, 2026 20:42
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-287-be-template-builder-fixes branch from 8868d03 to 9ec0473 Compare June 16, 2026 20:42
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-287-be-template-builder-fixes branch from 9ec0473 to df0f468 Compare June 17, 2026 15:59
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-286-fe-modulesettingsstep branch from bc5ca0b to 6723495 Compare June 17, 2026 15:59
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-287-be-template-builder-fixes branch from df0f468 to e41a23d Compare June 17, 2026 18:58
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-286-fe-modulesettingsstep branch from 6723495 to 4c13d89 Compare June 17, 2026 18:58
Implement the module settings wizard step:

- Add ModuleSettingsStep component that renders a ModuleConfiguration
  card per selected module with configurable variable fields
- Map non-sensitive variables to ConfigurationField definitions
  (switch for bool, text input for string/number)
- Show info notice for sensitive variables indicating they will be
  collected from developers at workspace creation
- Export moduleSettingsComplete helper to validate required fields
- Extend canContinue in PageView to gate module-settings step
- Wire the step into TemplateBuilderPageView with SET_MODULE_VARIABLES
  dispatch
…URL default

Terraform module registry source addresses must not include a URL
scheme. The default value 'https://registry.coder.com' produced
invalid source paths like 'https://registry.coder.com/coder/code-server/coder',
causing 'terraform init' to fail with 'failed to parse module
registry address'.

Change the default to 'registry.coder.com'.
… declarations

Sensitive variable blocks in module .tf.tmpl files and the modulegen
script were missing default = "", causing terraform plan to prompt
for values during template import.
The backend now accepts raw string values from callers (e.g. "anthropic")
and wraps them in HCL quotes automatically via hclQuote(). Previously
callers were required to send pre-quoted HCL literals, which is not a
reasonable API contract for frontend consumers.

- validateStringValue now validates raw strings (rejects interpolation
  and overlong values)
- toHCLLiteral wraps string values in quotes with proper escaping
- hclQuote handles backslash, quote, newline, and carriage return escaping
- null is passed through unquoted for all types
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-286-fe-modulesettingsstep branch from 4c13d89 to 9d3600f Compare June 18, 2026 13:43
@jeremyruppel jeremyruppel force-pushed the jeremy/devex-287-be-template-builder-fixes branch from e41a23d to 6589566 Compare June 18, 2026 13:43
Base automatically changed from jeremy/devex-286-fe-modulesettingsstep to main June 18, 2026 17:47
@datadog-coder

datadog-coder Bot commented Jun 18, 2026

Copy link
Copy Markdown

Pipelines

⚠️ Warnings

🚦 1 Pipeline job failed

ci | required   View in Datadog   GitHub Actions

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 6589566 | Docs | Give us feedback!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant