Skip to content

Commit 05fa2c5

Browse files
fix: add boundary config validation and path normalization
Update enable_boundary validation to treat empty/whitespace strings as unset using trimspace checks, so callers providing "" are handled consistently with null. Per-variable validations already reject empty strings. Bump to v4.9.2. Closes #797 Generated with OpenClaw using Claude
1 parent a7b6df6 commit 05fa2c5

2 files changed

Lines changed: 12 additions & 12 deletions

File tree

registry/coder/modules/claude-code/README.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Run the [Claude Code](https://docs.anthropic.com/en/docs/agents-and-tools/claude
1313
```tf
1414
module "claude-code" {
1515
source = "registry.coder.com/coder/claude-code/coder"
16-
version = "4.9.0"
16+
version = "4.9.2"
1717
agent_id = coder_agent.main.id
1818
workdir = "/home/coder/project"
1919
claude_api_key = "xxxx-xxxxx-xxxx"
@@ -67,7 +67,7 @@ The module writes the config to `~/.config/coder_boundary/config.yaml` automatic
6767
```tf
6868
module "claude-code" {
6969
source = "registry.coder.com/coder/claude-code/coder"
70-
version = "4.9.0"
70+
version = "4.9.2"
7171
agent_id = coder_agent.main.id
7272
workdir = "/home/coder/project"
7373
enable_boundary = true
@@ -87,7 +87,7 @@ Use this when the config file is provisioned separately or managed outside the t
8787
```tf
8888
module "claude-code" {
8989
source = "registry.coder.com/coder/claude-code/coder"
90-
version = "4.9.0"
90+
version = "4.9.2"
9191
agent_id = coder_agent.main.id
9292
workdir = "/home/coder/project"
9393
enable_boundary = true
@@ -109,7 +109,7 @@ For tasks integration with AI Bridge, add `enable_aibridge = true` to the [Usage
109109
```tf
110110
module "claude-code" {
111111
source = "registry.coder.com/coder/claude-code/coder"
112-
version = "4.9.0"
112+
version = "4.9.2"
113113
agent_id = coder_agent.main.id
114114
workdir = "/home/coder/project"
115115
enable_aibridge = true
@@ -138,7 +138,7 @@ data "coder_task" "me" {}
138138
139139
module "claude-code" {
140140
source = "registry.coder.com/coder/claude-code/coder"
141-
version = "4.9.0"
141+
version = "4.9.2"
142142
agent_id = coder_agent.main.id
143143
workdir = "/home/coder/project"
144144
ai_prompt = data.coder_task.me.prompt
@@ -161,7 +161,7 @@ This example shows additional configuration options for version pinning, custom
161161
```tf
162162
module "claude-code" {
163163
source = "registry.coder.com/coder/claude-code/coder"
164-
version = "4.9.0"
164+
version = "4.9.2"
165165
agent_id = coder_agent.main.id
166166
workdir = "/home/coder/project"
167167
@@ -217,7 +217,7 @@ Run and configure Claude Code as a standalone CLI in your workspace.
217217
```tf
218218
module "claude-code" {
219219
source = "registry.coder.com/coder/claude-code/coder"
220-
version = "4.9.0"
220+
version = "4.9.2"
221221
agent_id = coder_agent.main.id
222222
workdir = "/home/coder/project"
223223
install_claude_code = true
@@ -239,7 +239,7 @@ variable "claude_code_oauth_token" {
239239
240240
module "claude-code" {
241241
source = "registry.coder.com/coder/claude-code/coder"
242-
version = "4.9.0"
242+
version = "4.9.2"
243243
agent_id = coder_agent.main.id
244244
workdir = "/home/coder/project"
245245
claude_code_oauth_token = var.claude_code_oauth_token
@@ -312,7 +312,7 @@ resource "coder_env" "bedrock_api_key" {
312312
313313
module "claude-code" {
314314
source = "registry.coder.com/coder/claude-code/coder"
315-
version = "4.9.0"
315+
version = "4.9.2"
316316
agent_id = coder_agent.main.id
317317
workdir = "/home/coder/project"
318318
model = "global.anthropic.claude-sonnet-4-5-20250929-v1:0"
@@ -369,7 +369,7 @@ resource "coder_env" "google_application_credentials" {
369369
370370
module "claude-code" {
371371
source = "registry.coder.com/coder/claude-code/coder"
372-
version = "4.9.0"
372+
version = "4.9.2"
373373
agent_id = coder_agent.main.id
374374
workdir = "/home/coder/project"
375375
model = "claude-sonnet-4@20250514"

registry/coder/modules/claude-code/main.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,12 +227,12 @@ variable "enable_boundary" {
227227
default = false
228228

229229
validation {
230-
condition = !var.enable_boundary || var.boundary_config == null || var.boundary_config_path == null
230+
condition = !var.enable_boundary || (var.boundary_config == null || trimspace(var.boundary_config) == "") || (var.boundary_config_path == null || trimspace(var.boundary_config_path) == "")
231231
error_message = "Only one of boundary_config or boundary_config_path can be provided, not both."
232232
}
233233

234234
validation {
235-
condition = (var.boundary_config == null && var.boundary_config_path == null) || var.enable_boundary
235+
condition = ((var.boundary_config == null || trimspace(var.boundary_config) == "") && (var.boundary_config_path == null || trimspace(var.boundary_config_path) == "")) || var.enable_boundary
236236
error_message = "boundary_config and boundary_config_path can only be set when enable_boundary is true."
237237
}
238238
}

0 commit comments

Comments
 (0)