Skip to content

Add AWS vault-utils: Secrets Manager, KMS bootstrap, and Raft health - #4

Open
amitslog wants to merge 1 commit into
developfrom
feat/aws-vault-utils
Open

Add AWS vault-utils: Secrets Manager, KMS bootstrap, and Raft health#4
amitslog wants to merge 1 commit into
developfrom
feat/aws-vault-utils

Conversation

@amitslog

@amitslog amitslog commented Sep 5, 2026

Copy link
Copy Markdown

This slice adds the AWS path in vault-utils so an EC2 node can init once with KMS auto-unseal, write init and platform tokens to Secrets Manager, and fail closed if SM or unseal does not work. Health serve listens on 8210 and returns 200 only when this node is a Raft voter and caught up. Snapshots go to the connected S3 prefix when SNAPSHOT_BUCKET is set. backup_schedule is a cron expression. Empty means off.

ASG, NLB, AMI, and user-data are not in this PR.

How I validated

go test -short ./... passed. go test ./internal/vaultcluster passed (KeyStore, Raft health rule, S3 key/list, cron parse, plus existing isolation). go build ./cmd/vault-utils passed. Live Secrets Manager, KMS, S3, and a 3-node NLB were not run.

Review Note 1

Unit tests use in-memory fakes. bootstrap aws is not exercised against a real Vault with an AWS KMS seal. TestLocalComposeRuntime was not re-run (Docker Hub timeout). This branch does not change Compose.

Give EC2 a fail-closed path to init with KMS auto-unseal, store tokens in Secrets Manager, expose voter health on 8210, and write Raft snapshots to S3.
@amitslog
amitslog requested a review from BSick7 September 5, 2026 18:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant