Maven (nexus project release)

http://blog.sina.com.cn/s/blog_6fe280b701012trj.html

1.pom.xml configures the released release warehouse and snapshot warehouse

 <distributionManagement>
  <snapshotRepository>
   <id>snapshots-riil</id>
   <name>Snapshots</name>
   <url>http://172.16.13.111:8081/nexus/content/repositories/snapshots</url>
  </snapshotRepository>
  <repository>
   <id>releases-riil</id>
   <name>Releases</name>
   <url>http://172.16.13.111:8081/nexus/content/repositories/releases/</url>
  </repository>
 </distributionManagement>

Maven (nexus project release)
 

2. Default user permissions

nexus has three users by default

admin: system administrator

deployment: deployment permission

anonmous: access only

Maven (nexus project release)

3.Configuration in setting.xml

    <server>
      <id>snapshots-riil</id>
      <username>deployment</username>
      <password>deployment123</password>
    </server>
   
    <server>
      <id>releases-riil</id>
      <username>deployment</username>
      <password>deployment123</password>
    </server>

Maven (nexus project release)

4. Execute command deployment
Maven (nexus project release)

 

5. Check if the deployment is successful

Maven (nexus project release)

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326557779&siteId=291194637