diff --git a/.jenkinsfile b/.jenkinsfile index 836e879..1aa06d7 100644 --- a/.jenkinsfile +++ b/.jenkinsfile @@ -35,9 +35,11 @@ pipeline { def responseApi = httpRequest( url: env.GITEA_API_URL, httpMode: 'POST', - acceptType: 'application/json', - contentType: 'application/json', - customHeaders: [[name: 'Authorization', value: "token ${env.GITEA_TOKEN}"]], + customHeaders: [ + [name: 'Accept-Type', value: 'application/json'], + [name: 'Content-Type', value: 'application/json'], + [name: 'Authorization', value: 'token ' + env.GITEA_TOKEN], + ], requestBody: releaseData) def responseCode = responseApi.status @@ -78,7 +80,11 @@ pipeline { httpMode: 'POST', acceptType: 'application/json', contentType: 'application/octet-stream', - customHeaders: [[name: 'Authorization', value: "token ${env.GITEA_TOKEN}"]], + customHeaders: [ + [name: 'Accept-Type', value: 'application/json'], + [name: 'Content-Type', value: 'application/octet-stream'], + [name: 'Authorization', value: 'token ' + env.GITEA_TOKEN] + ], uploadFile: "build/libs/${fileName}") def responseCode = responseApi.status