-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Setting Use to clear out ACL tokens when switching stacks (#10)
- Loading branch information
1 parent
c805513
commit b4dbbbf
Showing
3 changed files
with
40 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
kind: Added | ||
body: Set Use to clear previous ACL tokens when called to avoid conflicts | ||
time: 2024-07-11T23:39:13.520023-05:00 | ||
custom: | ||
Author: Shackelford-Arden |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package cmd | ||
|
||
func unsetTokens(shell string) string { | ||
|
||
output := "" | ||
|
||
switch shell { | ||
case "bash": | ||
fallthrough | ||
case "zsh": | ||
fallthrough | ||
default: | ||
output = ` | ||
unset NOMAD_TOKEN | ||
unset CONSUL_TOKEN | ||
unset VAULT_TOKEN | ||
` | ||
} | ||
|
||
return output | ||
} |