chore: fix missing GRPC config
Some checks failed
Some checks failed
This commit is contained in:
parent
2ed3da7455
commit
1ee69505d7
1 changed files with 4 additions and 1 deletions
|
|
@ -1,10 +1,12 @@
|
|||
package cloud
|
||||
|
||||
import (
|
||||
"crypto/tls"
|
||||
_ "embed"
|
||||
|
||||
"github.com/evcc-io/evcc/util"
|
||||
"google.golang.org/grpc"
|
||||
"google.golang.org/grpc/credentials"
|
||||
)
|
||||
|
||||
var (
|
||||
|
|
@ -19,7 +21,8 @@ func Connection() (*grpc.ClientConn, error) {
|
|||
}
|
||||
|
||||
var err error
|
||||
conn, err = grpc.Dial(host)
|
||||
creds := credentials.NewTLS(new(tls.Config))
|
||||
conn, err = grpc.Dial(host, grpc.WithTransportCredentials(creds))
|
||||
|
||||
return conn, err
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue