chamber icon indicating copy to clipboard operation
chamber copied to clipboard

Improve documentation regarding parameter_store_key

Open indistinctTalk opened this issue 9 years ago • 3 comments

Currently the code defines parameter_store_key to be used in IAM's Encrypted keys.

var (
	// KeyID is the alias for the KMS key used to encrypt/decrypt secrets
	KeyID = "alias/parameter_store_key"
)

However this key doesn't exist by default and it isn't mentioned in the chamber documentation. You get the below error when trying to write secrets without it.

$ aws-vault exec development -- chamber write test Test "such test"
InvalidKeyId: Alias arn:aws:kms:eu-west-2:xxxx:alias/parameter_store_key is not found. (Service: AWSKMS; Status Code: 400; Error Code: NotFoundException; Request ID: xxxx)
	status code: 400, request id: xxxx

This threw me for a little spin because I wasn't sure if the issue lay elsewhere (i.e. aws-vault) or with chamber. I'm happy to make a pull request with an updated README if that's alright?

As an aside, maybe this is something that users should be able to specify incase they wanted to use a different key?

indistinctTalk avatar Aug 17 '17 07:08 indistinctTalk

That's a pretty good point @iJebus. Any ideas how we can improve it @dfuentes?

I feel like there might be an opportunity to make the alias configurable, but can't think of a way to do it sanely. Either way, we definitely need to document better

ejcx avatar Aug 19 '17 18:08 ejcx

Ran into this as well. Was pretty simple to setup though.

Jinkxed avatar Aug 21 '17 15:08 Jinkxed

Added some docs around this (and an alias override) in https://github.com/segmentio/chamber/pull/19

dfuentes avatar Aug 22 '17 21:08 dfuentes