9.Nexus私服安装配置
第一步:下载nexus-webapp-1.9.2.4.war包,然后复制到tomcat下的webapps文件夹中
第二步:启动tomcat
第三步:訪问http://localhost:8080/nexus/显演示样例如以下:
第四步:点击右上角“log in” ,输入username:admin和Password:admin123登录
第五步:登录成功
watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvdG90b3R1enVvcXVhbg==/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/SouthEast" border="0" style="width:908px; height:525px">
第六步:点击Views/Repositories中Repositories
watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvdG90b3R1enVvcXVhbg==/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/SouthEast" border="0">
Nexus内置仓库说明:
(1)Maven
Central:该仓库代理Maven中央仓库,其策略为Release,因此仅仅会下载和缓存中央仓库中的公布版本号构件。
(2)Releases:这是一种策略为Release的宿主类型仓库,用来部署组织内部的公布版本号构件。
(3)Snapshots:这是一个策略为Snapshot的宿主类型仓库。用来部署组织内部的快照版本号构件。
(4)3rd
party:这是一个策略为Release的宿主类型仓库。用来部署无法从公共仓库获得的第三方公布版本号构件。
(5)Public
Repositories:该仓库组将上述全部策略为Release的仓库聚合并通过一致的地址提供服务。
第七步:创建宿主文件夹和代理仓库
- Hosted:本地仓库,通常我们会部署自己的构件到这一类型的仓库。
- 包含3rd party仓库,Releases仓库。Snapshots仓库
- Proxy:代理仓库。它们被用来代理远程的公共仓库,如maven中央仓库。
- Group:仓库组,用来合并多个hosted/proxy仓库。通常我们配置maven依赖仓库组。
第八步:创建仓库组
点击Public
Repositories仓库,在Configurations栏中选取须要合并的仓库,点击箭头加到左边保存就可以
watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQvdG90b3R1enVvcXVhbg==/font/5a6L5L2T/fontsize/400/fill/I0JBQkFCMA==/dissolve/70/gravity/SouthEast" border="0">
第九步:下载Index索引并进行构建搜索(GAV搜索)
第十步:配置全部构建均从私服下载,在~/.m2/setting.xml中配置例如以下:
<settings>
<mirrors>
<mirror>
<!--此处配置全部的构建均从私有仓库中下载
*代表全部。也能够写central -->
<id>nexus</id>
<mirrorOf>*</mirrorOf>
<url>http://192.168.1.100:8000/nexus/content/groups/public</url>
</mirror>
</mirrors>
<profiles>
<profile>
<id>nexus</id>
<!—全部请求均通过镜像
-->
<repositories>
<repository>
<id>central</id>
<url>http://central</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>true</enabled></snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>http://central</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>true</enabled></snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<!--make the profile active all the time-->
<activeProfile>nexus</activeProfile>
</activeProfiles>
第十一步:部署构建到Nexus。包括Release和Snapshot。在项目根文件夹中pom.xml中配置:
<distributionManagement>
<repository>
<id>releases</id>
<name>Internal Releases</name>
<url>http://localhost:8000/nexus/content/repositories/releases/</url>
</repository>
<snapshotRepository>
<id>snapshots</id>
<name>Internal Snapshots</name>
<url>http://localhost:8000/nexus/content/repositories/snapshots/</url>
</snapshotRepository>
</distributionManagement>
第十二步:Nexus的訪问权限控制,在~/m2/setting.xml中配置例如以下:
<!--设置公布时的username
-->
<servers>
<server>
<id>releases </id>
<username>admin</username>
<password>admin123</password>
</server>
<server>
<id> snapshots </id>
<username>admin</username>
<password>admin123</password>
</server>
</servers>
9.Nexus私服安装配置的更多相关文章
- 【运维技术】Nexus私服安装配置常用问题
maven私服安装配置 软件安装及基本配置 安装配置 # 安装jdk,参考其他教程 mkdir -p /app/nexus2 # 创建目录 wget https://download.sonatype ...
- linux 搭建 nexus 私服及配置
安装篇 1.tar -zxvf nexus-latest-bundle.tar.gz 2.cd nexus-2.13.0-01/bin 3../nexus start 这时可能提示 ********* ...
- maven私服 Nexus2.x.x私服安装配置
一.Nexus的下载和安装 1.下载nexus ,下载地址:https://www.sonatype.com/download-oss-sonatype 2.打开目录nexus-2.x.x-xx-b ...
- nexus私服安装
一.搭建nexus私服.当前服务器版本是jdk1.8 . nexus安装包下载:http://www.sonatype.org/nexus/archived 先是下载目前最新的版本 Nexus ...
- Maven使用Nexus私服的配置
工作记录 —————————————————————————————— 配置文件 apache-maven-3.3.3\conf\settings.xml 在mirrors(镜像)之间配置. url为 ...
- Maven仓库Nexus的安装配置
1.下载nexus,最新版本是nexus-2.8.0-05 参考文章 下载nexus-latest-bundle.zip文件后,并解压到 D:\nexus下 配置nexus的环境变量:先配置NE ...
- nexus 私服 低配置服务器启动不能访问的问题
1核1G的渣渣服务器启动无法访问. 请更换更高配置的服务器.
- Linux 安装配置maven3.0 以及搭建nexus私服
http://carvin.iteye.com/blog/785365 一.软件准备 1.apache-maven-3.0-bin.tar.gz 下载地址:http://www.apache.org/ ...
- Linux安装配置maven以及搭建nexus私服(编写启动脚本)
2011年07月12日16:32 下面介绍在Linux操作系统下安装配置maven和搭建nexus私服. 一.安装前的准备 下载 jdk http://www.oracle.com/technetw ...
随机推荐
- 【剑指Offer面试题】 九度OJ1516:调整数组顺序使奇数位于偶数前面
题目链接地址: http://ac.jobdu.com/problem.php?pid=1516 题目1516:调整数组顺序使奇数位于偶数前面 时间限制:1 秒内存限制:128 兆特殊判题:否提交:2 ...
- C#派生类中使用基类protected成员的方法
我们知道C#中通过继承可以使一个具有公共数据和方法的基类被广泛应用从而减少代码量,这样派生类会具有基类中所有成员(除构造器等),我们理所当然可以通过派生类实例来使用基类的成员.那么当基类成员被prot ...
- JavaScript获取本机IP地址
<script type="text/javascript"> /** * Get the user IP throught the webkitRTCPeerConn ...
- 洛谷 P4148 简单题 KD-Tree 模板题
Code: //洛谷 P4148 简单题 KD-Tree 模板题 #include <cstdio> #include <algorithm> #include <cst ...
- iOS——扬声器与听筒的切换
1.扬声器模式: NSError *error; [[AVAudioSession sharedInstance] overrideOutputAudioPort:AVAudioSessionPor ...
- Conservative GC (Part two :MostlyCopyingGC )
目录 MostlyCopyingGC 概要 堆结构 分配 new_obj()函数 add_pages()函数 GC执行过程 mostly_copying()函数 promote_page()函数 pa ...
- 使用let's encrypt为你的Ubuntu14+nginx网站保驾护航!
finch最近正在研究一个新的网站系统,闲的没事想搞搞ssl,结果搞了两天,遇到很多问题,现在记录并分享一下经验. 环境之前搭建好了是Ubuntu14+nginx+php5+mysql 现在开始使用l ...
- [APIO2010]巡逻(树的直径)
[APIO2010]巡逻 题目描述 在一个地区中有 n 个村庄,编号为 1, 2, ..., n.有 n – 1 条道路连接着这些村 庄,每条道路刚好连接两个村庄,从任何一个村庄,都可以通过这些道路到 ...
- UVALive 6486 Skyscrapers 简单动态规划
题意: 有N个格子排成一排,在每个格子里填上1到N的数(每个只能填一次),分别代表每个格子的高度.现在给你两个数left和right,分别表示从左往右看,和从右往左看,能看到的格子数.问有多少种情况. ...
- 【SRM 717 DIV2 C】DerangementsDiv2
Problem Statement You are given two ints: n and m. Let D be the number of permutations of the set {1 ...