(c flags.FlagContext)
| 151 | } |
| 152 | |
| 153 | func (cmd Login) decideEndpoint(c flags.FlagContext) (string, bool) { |
| 154 | endpoint := c.String("a") |
| 155 | skipSSL := c.Bool("skip-ssl-validation") |
| 156 | if endpoint == "" { |
| 157 | endpoint = cmd.config.APIEndpoint() |
| 158 | skipSSL = cmd.config.IsSSLDisabled() || skipSSL |
| 159 | } |
| 160 | |
| 161 | if endpoint == "" { |
| 162 | endpoint = cmd.ui.Ask(T("API endpoint")) |
| 163 | } else { |
| 164 | cmd.ui.Say(T("API endpoint: {{.Endpoint}}", map[string]interface{}{"Endpoint": terminal.EntityNameColor(endpoint)})) |
| 165 | } |
| 166 | |
| 167 | return endpoint, skipSSL |
| 168 | } |
| 169 | |
| 170 | func (cmd Login) authenticateSSO(c flags.FlagContext) error { |
| 171 | prompts, err := cmd.authenticator.GetLoginPromptsAndSaveUAAServerURL() |
no test coverage detected