Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure Pipeline Maven task fails for unauthorized 401 error

I have a maven task in azure CI pipeline , where i want to publish my artifacts to feed in azure artifacts. I added a maven task with deploy as a goals and enable the authenticate builtin maven feed. But its throwing unauthorized 401 error , Can some one help me publishing my build artifacts to azure artifacts feed?

like image 967
Shubham Arya Avatar asked Sep 02 '25 07:09

Shubham Arya


1 Answers

I added a maven task with deploy as a goals and enable the authenticate builtin maven feed. But its throwing unauthorized 401 error , Can some one help me publishing my build artifacts to azure artifacts feed?

enter image description here

Add the Maven Authenticate task before calling Maven task to publish the artifact. The Maven Authenticate task can provide credentials for Azure Artifacts feeds and external Maven repositories in the current user's settings.xml file.

In addition: To publish package to Azure Devops feed, you'll need to make sure the 1.User Account you created the Service Connection(used in maven authenticate task) and the Project Build Service have at least Contributor role within the target feed.

Feed settings:

enter image description here

enter image description here

like image 85
LoLance Avatar answered Sep 05 '25 01:09

LoLance