Skip to content

Commit

Permalink
-agent-address flag should have higher precedence than the env var (#…
Browse files Browse the repository at this point in the history
…28574)

* -agent-address flag should have higher precedence than the env var

* add changelog
  • Loading branch information
raskchanky authored Oct 4, 2024
1 parent d1355cb commit 7307c56
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions changelog/28574.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:bug
cli: Fixed a CLI precedence issue where -agent-address didn't override VAULT_AGENT_ADDR as it should
```
2 changes: 1 addition & 1 deletion command/base.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ func (c *BaseCommand) Client() (*api.Client, error) {
config.Address = c.flagAddress
}
if c.flagAgentProxyAddress != "" {
config.Address = c.flagAgentProxyAddress
config.AgentAddress = c.flagAgentProxyAddress
}

if c.flagOutputCurlString {
Expand Down

0 comments on commit 7307c56

Please sign in to comment.