|
@@ -2,11 +2,14 @@
|
|
def GetLog(build_url) {
|
|
def GetLog(build_url) {
|
|
def logurl = build_url + 'consoleText'
|
|
def logurl = build_url + 'consoleText'
|
|
def strip = logurl.replaceAll('http://','')
|
|
def strip = logurl.replaceAll('http://','')
|
|
|
|
+ def creds = "admin:admin"
|
|
|
|
+ String auth = creds.bytes.encodeBase64().toString()
|
|
|
|
|
|
withCredentials([string(credentialsId: 'JenkinsAPI', variable: 'token')]){
|
|
withCredentials([string(credentialsId: 'JenkinsAPI', variable: 'token')]){
|
|
responce = httpRequest(contentType: 'APPLICATION_JSON',
|
|
responce = httpRequest(contentType: 'APPLICATION_JSON',
|
|
httpMode: 'GET',
|
|
httpMode: 'GET',
|
|
- url: 'http://admin:' + token +'@' + strip)
|
|
|
|
|
|
+ url: 'http:// + strip,
|
|
|
|
+ customHeaders:[[name:'Authorization', value:"Basic ${auth}"]])
|
|
return strip
|
|
return strip
|
|
}
|
|
}
|
|
}
|
|
}
|