Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy (default-deploy) on project app-yitian-community: Failed to deploy artifacts: Could not transfer artifact com.credlink:app-yitian-community:pom:1.0-20210913.112752-1 from/to yt-snapshots (http://xxx.xxx.xxx.xx:8081/nexus/content/repositories/snapshots): authentication failed for http://10.18.6.108:8081/nexus/content/repositories/snapshots/com/credlink/app-yitian-community/1.0-SNAPSHOT/app-yitian-community-1.0-20210913.112752-1.pom, status: 401 Unauthorized
报错:Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy
原因:缺少配置
解决:在Maven配置文件settings.xml中加配置
在目录…\apache-maven-3.2.3-bin\apache-maven-3.2.3\conf下打开文件settings.xml,增加配置。
<!-- servers
| This is a list of authentication profiles, keyed by the server-id used within the system.
| Authentication profiles ca