nexus的管理maven仓库

1)安装nexus

1、下载并且解压缩
2、将bin添加到环境变量
3、nexus install将nexus安装到windows的服务中
4、修改



5、nexus start启动服务



2)仓库类型

1、host的仓库。内部项目的发布仓库


2、proxy的仓库。从远程中央仓库中寻找数据的仓库


3、group仓库。组仓库用来方便开发人员进行设置的仓库



3)配置镜像(设置setting.xml)

	 <mirror>
      <id>central</id>
      <mirrorOf>*</mirrorOf><!--设置所有的工厂都加镜像-->
      <name>Human Readable Name for this Mirror.</name>
      <url>http://localhost:8081/nexus/content/groups/public/</url>
    </mirror>

激活profile

  <activeProfiles>
    <activeProfile>central</activeProfile>
  </activeProfiles>

4)项目发布

设定release工厂和snapshots工厂

  <distributionManagement>
  	<snapshotRepository>
  		<id>user-snapshots</id>
  		<name>User Project SNAPSHOTS</name>
  		<url>http://localhost:8081/nexus/content/repositories/snapshots</url>
  	</snapshotRepository>
  	<repository>
  	  	<id>user-releases</id>
  		<name>User Project SNAPSHOTS</name>
  		<url>http://localhost:8081/nexus/content/repositories/releases</url>
  	</repository>
  </distributionManagement>

设定发布工厂的权限(setting.xml)

    <server>
      <id>user-snapshots</id>
      <privateKey>deployment</privateKey>
      <passphrase>deployment</passphrase>
    </server>
    <server>
      <id>user-releases</id>
      <privateKey>deployment</privateKey>
      <passphrase>deployment</passphrase>
    </server>

5)创建工厂

1、创建两个工厂:release和policy的

2、配置权限




3、创建角色并且分配权限


4、创建用户


5、创建发布的工厂


评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值