Skip to content

Commit 50f4d53

Browse files
matthazinskiclaudeDevelopmentCats
authored
fix(codex): pass folder variable to agentapi module (#477)
## Description The folder variable was not being passed from the codex module to the agentapi module, causing agentapi to use its default value of `/home/coder` instead of the user-specified folder path. This resulted in permission errors when the codex module tried to create directories in `/home/coder` when users specified a different folder like `/home/matt/foo`. Fix by adding `folder = var.folder` to the agentapi module invocation. ## Type of Change - [ ] New module - [ ] New template - [x] Bug fix - [ ] Feature/enhancement - [ ] Documentation - [ ] Other ## Module Information Path: registry/coder-labs/modules/codex New version: v2.1.1 Breaking change: [ ] Yes [X] No ## Testing & Validation - [x] Tests pass (`bun test`) - [x] Code formatted (`bun fmt`) - [x] Changes tested locally ## Related Issues Fixes #476 --------- Co-authored-by: Claude <noreply@anthropic.com> Co-authored-by: DevelopmentCats <christofer@coder.com>
1 parent 36943d1 commit 50f4d53

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

registry/coder-labs/modules/codex/README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Run Codex CLI in your workspace to access OpenAI's models through the Codex inte
1313
```tf
1414
module "codex" {
1515
source = "registry.coder.com/coder-labs/codex/coder"
16-
version = "2.1.0"
16+
version = "2.1.1"
1717
agent_id = coder_agent.example.id
1818
openai_api_key = var.openai_api_key
1919
folder = "/home/coder/project"
@@ -33,7 +33,7 @@ module "codex" {
3333
module "codex" {
3434
count = data.coder_workspace.me.start_count
3535
source = "registry.coder.com/coder-labs/codex/coder"
36-
version = "2.1.0"
36+
version = "2.1.1"
3737
agent_id = coder_agent.example.id
3838
openai_api_key = "..."
3939
folder = "/home/coder/project"
@@ -60,7 +60,7 @@ module "coder-login" {
6060
6161
module "codex" {
6262
source = "registry.coder.com/coder-labs/codex/coder"
63-
version = "2.1.0"
63+
version = "2.1.1"
6464
agent_id = coder_agent.example.id
6565
openai_api_key = "..."
6666
ai_prompt = data.coder_parameter.ai_prompt.value
@@ -106,7 +106,7 @@ For custom Codex configuration, use `base_config_toml` and/or `additional_mcp_se
106106
```tf
107107
module "codex" {
108108
source = "registry.coder.com/coder-labs/codex/coder"
109-
version = "2.1.0"
109+
version = "2.1.1"
110110
# ... other variables ...
111111
112112
# Override default configuration

registry/coder-labs/modules/codex/main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ module "agentapi" {
131131
version = "1.2.0"
132132

133133
agent_id = var.agent_id
134+
folder = var.folder
134135
web_app_slug = local.app_slug
135136
web_app_order = var.order
136137
web_app_group = var.group

0 commit comments

Comments
 (0)