This repository was archived by the owner on Feb 16, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Create a Native State BackendΒ #32
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or requesthelp wantedExtra attention is neededExtra attention is needed
Description
We're currently using the secrethub-http-proxy as an HTTP state backend now, but preferably we'd like to write a custom state backend.
However, seeing as state backends aren't pluggable yet we will have to create a fork of the Terraform project and add our state there. For people to actually be able to use the backend though, we'd have to get it merged back into the Terraform project and included in the next release.
If you want us to push this native backend through, please take a moment to +1 π this issue and we'll prioritize it on the roadmap.
Implementation details
Technically speaking, it shouldn't be too difficult a task:
- Add a folder
backend/remote-state/secrethub: https://github.com/hashicorp/terraform/tree/master/backend/remote-state - Implement the
backend.Backendinterface. For inspiration, check out the S3 and HTTP implementations: - Looking at the patterns other backends use, we would then create a small wrapper around the
secrethub-go/pkg/secrethub.Clientinterface that implements the Terraform specific logic, similar to thehttpClienttype and have oursecrethub.Backendtype use that. - Most of the thinking for what the code should do in the
Get,Update,Deletefunctions is actually already done in the proxy for the HTTPGET,UPDATE, andDELETEhandler functions. - Submit a PR and bob's your uncle π
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requesthelp wantedExtra attention is neededExtra attention is needed