-
Add optional methods attribute to the arrstack role resource (#3)
ci/woodpecker/tag/release Pipeline was successfulreleased this
2026-08-30 17:05:47 +10:00 | 0 commits to main since this releaseWhy
Engine plugin v0.2.0 added a
methodsfield to arrstack roles, pinning a minted arrproxy key to a set of HTTP methods so a read-only integration can be handed a key that cannot write. The provider had no way to express it, so those roles could not be managed fromterraform-vault.How
- Adds an optional
methodsset attribute toarrstack_secret_backend_role, validated at plan time againstGET/HEAD/POST/PUT/PATCH/DELETE/OPTIONS(upper case only, since the engine stores them upper-cased and a lower-case value would drift on every plan). - Always writes
methods: the engine only clears an existing scope when the key is present, so an omitted key would leave a stale scope behind. - Reads an unrestricted role back as null rather than an empty set, so a config that omits
methodsshows no drift; a scope cleared out of band still surfaces as a diff. - Documents the attribute in the README and both example configs.
- Tests cover the write mapping (null and populated), the read-back cases (absent/empty/null/cleared), and the plan-time validator.
Dependency: engine plugin >= 0.2.0.
Reviewed-on: #3
Co-authored-by: unkin-agent unkin-agent@unkin.net
Co-committed-by: unkin-agent unkin-agent@unkin.netDownloads
- Adds an optional