Skip to content

Commit

Permalink
Add SkipGetServer in connect args
Browse files Browse the repository at this point in the history
Signed-off-by: Gabriel Adrian Samfira <[email protected]>
  • Loading branch information
gabriel-samfira committed May 23, 2024
1 parent cb0f23e commit fabba4d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion provider/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ func getClientFromConfig(ctx context.Context, cfg *config.LXD) (cli lxd.Instance
}

if cfg.UnixSocket != "" {
return lxd.ConnectLXDUnixWithContext(ctx, cfg.UnixSocket, nil)
return lxd.ConnectLXDUnixWithContext(ctx, cfg.UnixSocket, &lxd.ConnectionArgs{SkipGetServer: true})
}

if cfg.URL == "" {
Expand Down Expand Up @@ -150,6 +150,7 @@ func getClientFromConfig(ctx context.Context, cfg *config.LXD) (cli lxd.Instance
TLSCA: string(tlsCAContents),
TLSClientCert: string(clientCertContents),
TLSClientKey: string(clientKeyContents),
SkipGetServer: true,
}

lxdCLI, err := lxd.ConnectLXD(cfg.URL, &connectArgs)
Expand Down

0 comments on commit fabba4d

Please sign in to comment.