feat: import new modules and refactor codegen script (#26838)

This commit is contained in:
Jeremy Ruppel
2026-06-29 17:47:06 -04:00
committed by GitHub
parent e58806cb75
commit 7daf3123cb
12 changed files with 594 additions and 16 deletions
+3 -1
View File
@@ -32,7 +32,7 @@ variable "{{ .Name }}" {
{{ end -}}
module "{{ .ID }}" {
count = data.coder_workspace.me.start_count
source = "{{"{{"}} .RegistryBase {{"}}"}}/coder/{{ .ID }}/coder"
source = "{{"{{"}} .RegistryBase {{"}}"}}/{{ .Namespace }}/{{ .ID }}/coder"
version = "{{"{{"}} .PinnedVersion {{"}}"}}"
agent_id = coder_agent.{{"{{"}} .AgentResourceName {{"}}"}}.id
{{- range .NonComputedVars }}
@@ -47,6 +47,7 @@ module "{{ .ID }}" {
type tfTmplData struct {
ID string
Namespace string
SensitiveVars []ModuleVariable
NonComputedVars []ModuleVariable
}
@@ -66,6 +67,7 @@ func writeTFTmpl(path string, m ModuleManifest) error {
data := tfTmplData{
ID: m.ID,
Namespace: m.Namespace,
SensitiveVars: sensitiveVars,
NonComputedVars: nonComputedVars,
}