Fix TLS client bug

The CA bundle must be set on RootCAs to properly validate the remote server.

Signed-off-by: Gabriel Adrian Samfira <gsamfira@cloudbasesolutions.com>
This commit is contained in:
Gabriel Adrian Samfira 2023-08-20 15:48:56 +00:00
parent bc0a34bae9
commit 073ea1175e

View file

@ -86,7 +86,7 @@ func GithubClient(ctx context.Context, token string, credsDetails params.GithubC
}
httpTransport := &http.Transport{
TLSClientConfig: &tls.Config{
ClientCAs: roots,
RootCAs: roots,
},
}
httpClient := &http.Client{Transport: httpTransport}