1
0
mirror of https://github.com/woodpecker-ci/woodpecker.git synced 2024-11-24 08:02:18 +02:00

Allow to skip verify in oauths requests

This commit is contained in:
Kirill Zaitsev 2015-02-24 00:27:17 +03:00
parent 436b7a6e2a
commit 961a91dd23

View File

@ -1,6 +1,7 @@
package gitlab
import (
"crypto/tls"
"fmt"
"io/ioutil"
"net/http"
@ -278,6 +279,10 @@ func (r *Gitlab) GetToken(user *model.User) (*model.Token, error) {
RefreshToken: user.Secret,
Expiry: expiry,
},
Transport: &http.Transport{
Proxy: http.ProxyFromEnvironment,
TLSClientConfig: &tls.Config{InsecureSkipVerify: r.SkipVerify},
},
}
if err := t.Refresh(); err != nil {