I use the claude module to install claude code into the workspace. I have disabled report_tasks and cli_app as because the idle CPU usage is high on the claude agent (~ quarter core on each workspace adds up with many workspaces).
module "claude-code" {
count = data.coder_workspace.me.start_count
source = "registry.coder.com/coder/claude-code/coder"
version = "4.2.8"
agent_id = coder_agent.main.id
workdir = "/home/coder"
install_claude_code = true
claude_code_version = "latest"
report_tasks = false # Disable since we don't want the agent running
cli_app = false # Claude Code CLI app button in Coder UI
}