Esta página aún no está disponible en su idioma local. Estamos trabajando arduamente para agregar más versiones de idiomas. Gracias por tu apoyo.
CodeArts Artifact
CodeArts Artifact
- Service Overview
-
Getting Started
- Getting Started with a Release Repo
- Getting Started with a Self-hosted Repo
- Releasing/Obtaining a Maven Component via a Build Task
- Releasing/Obtaining an npm Component via a Build Task
- Releasing/Obtaining a Go Component via a Build Task
- Releasing/Obtaining a PyPI Component via a Build Task
- Uploading/Obtaining an RPM Component Using Linux Commands
- Uploading/Obtaining a Debian Component Using Linux Commands
- User Guide
-
FAQs
- Release Repo
-
Self-Hosted Repo
- How Do I Upload Snapshots to the Self-hosted Maven Repo?
- How Do I Call a Private Component from a Self-hosted Maven Repo?
- Can I Call Software Packages in Self-hosted Repos During Local Builds?
- Why Is Error Code 500 Returned When a Gradle Build Task Uploads a Maven Package?
- Why Can't the Repository Receive Requests?
- Why Did the Dependency WAR or JAR Files Fail to Be Downloaded?
- Why Is Error 401 Returned When Uploading Maven Components to Self-hosted Repos?
On this page
Show all
Help Center/
CodeArts Artifact/
FAQs/
Self-Hosted Repo/
Why Is Error 401 Returned When Uploading Maven Components to Self-hosted Repos?
Why Is Error 401 Returned When Uploading Maven Components to Self-hosted Repos?
Updated on 2023-11-28 GMT+08:00
Symptom
Failed to upload Maven components to self-hosted repos from the local IDE, and 401-Insufficient Permission is displayed.
Cause Analysis
The self-hosted repo information configured in the code repository file pom.xml does not match the settings.xml file.
Solution
When uploading the components, replace the repository_id value in the distributionManagement element of the pom.xml file with the repository_id value in the server element of the settings.xml file.
The uploading process is as follows:
- Access the self-hosted repo homepage, and choose Maven from the repository list.
- Click Set Me Up in the upper right corner. The Configuration Guide dialog box is displayed.
- Configure the local Maven tool by following the configuration guide.
- Run mvn deploy to upload the Maven project.
- In the Maven CLI, access the directory where the pom.xml file of the Maven project is stored, check whether the repository_id value in the distributionManagement element of the pom.xml file matches the repository_id value in the server element of the settings.xml file.
- Upload the local JAR package:
mvn deploy:deploy-file -DgroupId=com. -DartifactId=aopalliance -Dversion=1.0 -Dpackagi=jar
- In the Maven CLI, access the directory where the pom.xml file of the Maven project is stored, check whether the repository_id value in the distributionManagement element of the pom.xml file matches the repository_id value in the server element of the settings.xml file.
Parent topic: Self-Hosted Repo
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.
The system is busy. Please try again later.