Skip to content

Commit

Permalink
fix: cli also accepts IONSCALE_KEYS_SYSTEM_ADMIN_KEY env variable
Browse files Browse the repository at this point in the history
  • Loading branch information
jsiebens committed Feb 3, 2024
1 parent 5e43014 commit dea6027
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion internal/cmd/target.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (

const (
ionscaleSystemAdminKey = "IONSCALE_SYSTEM_ADMIN_KEY"
ionscaleKeysSystemAdminKey = "IONSCALE_KEYS_SYSTEM_ADMIN_KEY"
ionscaleAddr = "IONSCALE_ADDR"
ionscaleInsecureSkipVerify = "IONSCALE_SKIP_VERIFY"
)
Expand Down Expand Up @@ -56,5 +57,5 @@ func (t *Target) getSystemAdminKey() string {
if len(t.systemAdminKey) != 0 {
return t.systemAdminKey
}
return config.GetString(ionscaleSystemAdminKey, "")
return config.GetString(ionscaleSystemAdminKey, config.GetString(ionscaleKeysSystemAdminKey, ""))
}

0 comments on commit dea6027

Please sign in to comment.