Skip to content

Commit 2fd910a

Browse files
committed
Replace DisableCLIAuthFlow with CLIAuthFlow
Signed-off-by: Jan-Otto Kröpke <[email protected]>
1 parent 57a45bb commit 2fd910a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

core/auth/auth.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ func DefaultAuth(cfg *config.Configuration) (rt http.RoundTripper, err error) {
9393
rt, err = TokenAuth(cfg)
9494
if err != nil {
9595
tokenFlowErr := err
96-
if cfg.DisableCLIAuthFlow {
96+
if !cfg.CLIAuthFlow {
9797
err = errors.New("CLI flow disabled")
9898
} else {
9999
// Stackit CLI flow

core/config/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ type Configuration struct {
9090
CredentialsFilePath string `json:"credentialsFilePath,omitempty"`
9191
TokenCustomUrl string `json:"tokenCustomUrl,omitempty"`
9292
Region string `json:"region,omitempty"`
93-
DisableCLIAuthFlow bool `json:"disableCLIAuthFlow,omitempty"` // Should be set to true, if called by STACKIT CLI to avoid infinite loops.
93+
CLIAuthFlow bool `json:"cliAuthFlow,omitempty"`
9494
CustomAuth http.RoundTripper
9595
Servers ServerConfigurations
9696
OperationServers map[string]ServerConfigurations

0 commit comments

Comments
 (0)