alunduil / alunduil/alunduil-infrastructure
Read-only Terraform and repo sensors run prompt-free from a committed .claude/settings.json
- 主要語言
- Shell
- 星號
- 0
- 分支
- 0
- 平均合併
- 6 小時 30 分鐘
- 30 天內合併 PR
- 97
描述
## Summary
Commit a `.claude/settings.json` with a read-only allowlist so Terraform inspection and this repo's sensors run without permission prompts.
## Motivation
Permissions here come entirely from the host-wide chezmoi-deployed `~/.claude/settings.json`, which a fresh clone, a collaborator, or a cloud agent does not have. alunduil/zfs-replicate#427 shipped this pattern already; alunduil/network-uri-json#86 and alunduil/zellij-claude-pair#28 track it for those repos.
## Open question — gates the rest
Whether remote or cloud Claude Code environments read a committed `.claude/settings.json` is unverified, and the portability argument rests on it. Confirm before implementing.
## Scope
- `.claude/settings.json` allowing read-only Terraform — `terraform validate`, `terraform fmt -check`, `terraform providers`, `terraform version` — plus this repo's sensors
- Decide `terraform plan` explicitly: it refreshes remote state and needs credentials, so it is not obviously read-only
- `terraform apply` and `terraform destroy` stay prompted. The host-wide `ask` rules should not be the only thing stopping them, since a clone without those rules would not have them
- Read-only entries only; no secrets and no pointers to where credentials live
- Omit anything Claude Code auto-allows outright (`git` read-only subcommands, coreutils)
- Confirm `.claude/settings.local.json` is gitignored, and drop the dead session scratchpad path it currently carries
## Acceptance criteria
- [ ] `.claude/settings.json` is committed, read-only only, and contains no secrets
- [ ] `terraform apply` and `terraform destroy` still prompt with the file in place
- [ ] A decision on `terraform plan` is recorded in the issue or the file
- [ ] `.claude/settings.local.json` is gitignored and free of dead scratchpad paths
## Additional context
Trigger: an allowlist audit of the host-wide template, which found `Bash(terraform:*)` granted globally to all 54 repos on the host while only this one uses it.
Sibling, same open question in another repo: alunduil/alunduil-chezmoi#428.
貢獻指南
這個儲存庫沒有索引到貢獻指南
評估
這個 Issue 還沒有評估資料。