|
@@ -24,7 +24,10 @@ func Join(cfg *config.ClientConfig, privateKey string) error {
|
|
|
// Do that before the Joining Network flow by performing the end point auth flow
|
|
|
// if performed successfully an access key is obtained from the server and then we
|
|
|
// proceed with the usual flow 'pretending' that user is feeded us with an access token
|
|
|
- logger.Log(1, "Logging into %s via:", cfg.Network, cfg.SsoServer)
|
|
|
+ if len(cfg.Network) == 0 || cfg.Network == "all" {
|
|
|
+ return fmt.Errorf("no network provided. Specify network with \"-n <net name>\"")
|
|
|
+ }
|
|
|
+ logger.Log(1, fmt.Sprintf("Logging into %s via:", cfg.Network), cfg.SsoServer)
|
|
|
err = functions.JoinViaSSo(cfg, privateKey)
|
|
|
if err != nil {
|
|
|
logger.Log(0, "Join via OIDC failed: ", err.Error())
|