Can't deploy mule project to gitlab maven repository - 401 Unauthorised

Describe your question in as much detail as possible:

  • We are new to GitLab and when trying to deploy the package to GitLab maven repository, getting 401 Unauthorised error for the mule project
    • I have been following the shared document and the example project for creating my project. But still resulting in Unauthorised. While trying to deploy, in maven verbose logging, not seeing the token passing.

[DEBUG] << “HTTP/1.1 401 Unauthorized[\r][\n]”
[DEBUG] << “Server: nginx[\r][\n]”
[DEBUG] << “Date: Wed, 04 Mar 2020 18:54:40 GMT[\r][\n]”
[DEBUG] << “Content-Type: application/json[\r][\n]”
[DEBUG] << “Content-Length: 30[\r][\n]”
[DEBUG] << “Cache-Control: no-cache[\r][\n]”
[DEBUG] << “Vary: Origin[\r][\n]”
[DEBUG] << “X-Content-Type-Options: nosniff[\r][\n]”
[DEBUG] << “X-Frame-Options: SAMEORIGIN[\r][\n]”
[DEBUG] << “X-Request-Id: 878af20d-0724-463d-b7e1-51e635960480[\r][\n]”
[DEBUG] << “X-Runtime: 0.015801[\r][\n]”
[DEBUG] << “RateLimit-Limit: 600[\r][\n]”
[DEBUG] << “RateLimit-Observed: 3[\r][\n]”
[DEBUG] << “RateLimit-Remaining: 597[\r][\n]”
[DEBUG] << “RateLimit-Reset: 1583348140[\r][\n]”
[DEBUG] << “RateLimit-ResetTime: Wed, 04 Mar 2020 18:55:40 GMT[\r][\n]”
[DEBUG] << “GitLab-LB: fe-16-lb-gprd[\r][\n]”
[DEBUG] << “GitLab-SV: localhost[\r][\n]”
[DEBUG] << “[\r][\n]”
[DEBUG] Receiving response: HTTP/1.1 401 Unauthorized
[DEBUG] << HTTP/1.1 401 Unauthorized
[DEBUG] << Server: nginx
[DEBUG] << Date: Wed, 04 Mar 2020 18:54:40 GMT
[DEBUG] << Content-Type: application/json
[DEBUG] << Content-Length: 30
[DEBUG] << Cache-Control: no-cache
[DEBUG] << Vary: Origin
[DEBUG] << X-Content-Type-Options: nosniff
[DEBUG] << X-Frame-Options: SAMEORIGIN
[DEBUG] << X-Request-Id: 878af20d-0724-463d-b7e1-51e635960480
[DEBUG] << X-Runtime: 0.015801
[DEBUG] << RateLimit-Limit: 600
[DEBUG] << RateLimit-Observed: 3
[DEBUG] << RateLimit-Remaining: 597
[DEBUG] << RateLimit-Reset: 1583348140
[DEBUG] << RateLimit-ResetTime: Wed, 04 Mar 2020 18:55:40 GMT
[DEBUG] << GitLab-LB: fe-16-lb-gprd
[DEBUG] << GitLab-SV: localhost
[DEBUG] Connection can be kept alive indefinitely
[DEBUG] Authentication required
[DEBUG] requested authentication
[DEBUG] Response contains no authentication challenges
[DEBUG] << “{“message”:“401 Unauthorized”}”*

  • we are using
  • Have tried with both access-token and job-token with API scope

Thanks for taking the time to be thorough in your request, it really helps! :blush:


Hello, I’m wondering if you found the solution to your problem? I am experiencing the same issue.

Hi, When I checked, headers configuration was not supported in Mule 4.2.x . Heard this has been fixed in 4.3.0 version (but I haven’t verified that)

1 Like