-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clarify api_addr related errors on VaultPluginTLSProvider #3620
Conversation
helper/pluginutil/tls.go
Outdated
@@ -146,19 +146,19 @@ func VaultPluginTLSProvider(apiTLSConfig *api.TLSConfig) func() (*tls.Config, er | |||
|
|||
addrRaw := wt.Claims().Get("addr") | |||
if addrRaw == nil { | |||
return nil, errors.New("decoded token does not contain primary cluster address") | |||
return nil, errors.New("decoded token does not contain primary cluster api_address") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This error message isn't really good (originally, not due to your change) -- it's not really "primary cluster" it's "active node". But really just, the originating Vault process.
@@ -32,6 +32,9 @@ plugin process' environment. This token is single use and has a short TTL. Once | |||
unwrapped, it provides the plugin with a uniquely generated TLS certificate and | |||
private key for it to use to talk to the original vault process. | |||
|
|||
The [`api_addr`][api_addr] must be set in order for the plugin process establish | |||
communication with the Vault server during mount time. | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might want a note here (and below) about when this will be set automatically.
helper/pluginutil/tls.go
Outdated
@@ -146,19 +146,19 @@ func VaultPluginTLSProvider(apiTLSConfig *api.TLSConfig) func() (*tls.Config, er | |||
|
|||
addrRaw := wt.Claims().Get("addr") | |||
if addrRaw == nil { | |||
return nil, errors.New("decoded token does not contain primary cluster address") | |||
return nil, errors.New("decoded token does not contain the active node's api_address") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we are going to underscore it here it should probably be api_addr
to match the config value
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just one small comment, otherwise looks good!
* Mention api_addr on VaultPluginTLSProvider logs, update docs * Clarify message and mention automatic api_address detection * Change error message to use api_addr * Change error messages to use api_addr
* oss/master: changelog++ Support MongoDB session-wide write concern (#3646) Clarify api_addr related errors on VaultPluginTLSProvider (#3620) allowed/disallowed_policies as TypeCommaStringSlice (#3641) Update example payload and response for pem_keys field which needs \n after header and before footer in order to be accepted as a valid RSA or ECDSA public key (#3632) Docs: Update /sys/policies/ re: beta refs to address #3624 (#3629) Update secrets page Remove beta notice Expanding on the quick start guide with how to set up an intermediate authority (#3622) Docs: mlock() notes, fixes #3605 (#3614) Fix spelling (#3609) Add command to example to register plugin (#3601) update relatedtools, add Goldfish UI. (#3597) Fix docs for Transit API (#3588) Update cassandra docs with consistency value. Remove Trailing White space in Kubernetes Doc (#3360) Missing command for vault PUT operation (#3355) Update some rekey docs
Closes #3612