Add env var to skip TLS verify
This makes it much easier to debug with mitmproxy
This commit is contained in:
parent
6cccc16031
commit
ca88a0eaab
1 changed files with 7 additions and 0 deletions
|
|
@ -1,6 +1,8 @@
|
|||
package stadia
|
||||
|
||||
import (
|
||||
"crypto/tls"
|
||||
"os"
|
||||
"resty.dev/v3"
|
||||
//"github.com/rs/zerolog/log"
|
||||
)
|
||||
|
|
@ -17,6 +19,11 @@ func NewStadiaMaps(api_key string) *StadiaMaps {
|
|||
//r := resty.New().SetLogger(logger).SetDebug(true)
|
||||
//r := resty.New().SetDebug(true)
|
||||
r := resty.New()
|
||||
if os.Getenv("STADIA_INSECURE_SKIP_VERIFY") != "" {
|
||||
r.SetTLSClientConfig(&tls.Config{
|
||||
InsecureSkipVerify: true,
|
||||
})
|
||||
}
|
||||
return &StadiaMaps{
|
||||
APIKey: api_key,
|
||||
client: r,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue