diff --git a/cli/packages/cmd/login.go b/cli/packages/cmd/login.go index 8f29c907a1..81bb0c7549 100644 --- a/cli/packages/cmd/login.go +++ b/cli/packages/cmd/login.go @@ -315,7 +315,11 @@ var loginCmd = &cobra.Command{ credential, err := authStrategies[strategy](cmd, infisicalClient) if err != nil { - util.HandleError(fmt.Errorf("unable to authenticate with %s [err=%v]", formatAuthMethod(loginMethod), err)) + euErrorMessage := "" + if strings.HasPrefix(config.INFISICAL_URL, util.INFISICAL_DEFAULT_US_URL) { + euErrorMessage = fmt.Sprintf("\nIf you are using the Infisical Cloud Europe Region, please switch to it by using the \"--domain %s\" flag.", util.INFISICAL_DEFAULT_EU_URL) + } + util.HandleError(fmt.Errorf("unable to authenticate with %s [err=%v].%s", formatAuthMethod(loginMethod), err, euErrorMessage)) } if plainOutput { diff --git a/docs/cli/commands/commands.mdx b/docs/cli/commands/commands.mdx index 78870defc7..278f061b72 100644 --- a/docs/cli/commands/commands.mdx +++ b/docs/cli/commands/commands.mdx @@ -11,6 +11,7 @@ description: "Infisical CLI command overview" | `init` | Used to link a local project to the platform. | | `run` | Used to inject envars from the platform into an application process. | | `vault` | Used to manage where your login credentials are stored at rest | + ## Global options | Option | Description |