Add skip verify on the client for now
This commit is contained in:
parent
4821a90143
commit
9b03ffb7f1
1 changed files with 7 additions and 1 deletions
|
@ -1,6 +1,7 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"crypto/tls"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
|
@ -16,6 +17,7 @@ import (
|
||||||
"github.com/mdiluz/rove/proto/roveapi"
|
"github.com/mdiluz/rove/proto/roveapi"
|
||||||
"golang.org/x/net/context"
|
"golang.org/x/net/context"
|
||||||
"google.golang.org/grpc"
|
"google.golang.org/grpc"
|
||||||
|
"google.golang.org/grpc/credentials"
|
||||||
)
|
)
|
||||||
|
|
||||||
var home = os.Getenv("HOME")
|
var home = os.Getenv("HOME")
|
||||||
|
@ -185,8 +187,12 @@ func InnerMain(command string, args ...string) error {
|
||||||
return fmt.Errorf("no host set in %s, set one with '%s config {HOST}'", ConfigPath(), os.Args[0])
|
return fmt.Errorf("no host set in %s, set one with '%s config {HOST}'", ConfigPath(), os.Args[0])
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tls := &tls.Config{
|
||||||
|
InsecureSkipVerify: true,
|
||||||
|
}
|
||||||
|
|
||||||
// Set up the server
|
// Set up the server
|
||||||
clientConn, err := grpc.Dial(fmt.Sprintf("%s:%d", config.Host, gRPCport), grpc.WithInsecure())
|
clientConn, err := grpc.Dial(fmt.Sprintf("%s:%d", config.Host, gRPCport), grpc.WithTransportCredentials(credentials.NewTLS(tls)))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue