在操作系统Centos 6.3 上使用Nexus 2.8搭建MAVEN私服 及 cloudstack 开发环境
来源:互联网 发布:简单快递单打印软件 编辑:程序博客网 时间:2024/04/29 08:10
为了使用cloudstack 4.3做一些二次开发,接触到MAVEN,尝试并搭建了MAVEN私服。具体步骤如下:
1、Maven下载安装
1> 准备文件系统
lvcreate -L 43000m -n lvmvn vg00
mkfs.ext4 /dev/vg00/lvmvn
echo "/dev/mapper/vg00-lvmvn /maven ext4 defaults 1 2" >> /etc/fstab
mkdir /maven
mount /maven
2> 下载
wget http://apache.dataguru.cn/maven/maven-3/3.2.1/binaries/apache-maven-3.2.1-bin.tar.gz
3> 安装
cd /maven
tar -zxvf apache-maven-3.2.1.bin.tar.gz
4> 添加环境变量
vi /etc/profile
export M2_HOME=/vpool/maven/apache-maven-3.1.1
export JAVA_HOME=/vpool/jdk/jdk1.6.0_26
export PATH=$PATH:$M2_HOME/bin:$JAVA_HOME/bin
2、Nexus下载安装
1> 下载
使用wget 从http://www.sonatype.org/nexus/下载 Nexus 2.8版本,若不能直接访问,可以先通过export http_proxy设置代理
2> 安装
cd /maven/
tar -xvf nexus-2.8.0-05-bundle.tar
3> 启动
vi /maven/nexus-2.8.0-05/bin/nexus 修改RUN_AS_USER=root
/maven/nexus-2.8.0-05/bin/nexus start
3、Nexus配置
通过http://<ip>8081/nexus/ 直接访问Nexus管理界面,默认用户名密码为: admin / admin123
点击左侧 Repositories,将如下三项目中的Configuration中的Download Remote indexs修改为true:
设置Nexus上网代理:点击左侧Server
再分别右键上述三个proxy Repo选择Repair Index 让Nexus远程下载索引文件:
4、修改maven配置,并手动更新
vi /maven/apache-maven-3.2.1/conf/settings.xml,添加如下内容:
....
<mirror>
<id>nexus</id>
<mirrorOf>*</mirrorOf>
<name>Nexus IRE</name>
<url>http://10.45.25.40:8081/nexus/content/groups/public/</url>
</mirror>
...
<profile>
<id>ire_vpool</id>
<repositories>
<repository>
<id>nexus</id>
<name>local private nexus</name>
<url>http://10.45.30.201:8080/nexus/content/groups/public/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>nexus</id>
<name>local private nexus</name>
<url>http://10.45.30.201:8080/nexus/content/groups/public/</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
mvn help:system
5、eclipse配置
- 在操作系统Centos 6.3 上使用Nexus 2.8搭建MAVEN私服 及 cloudstack 开发环境
- Centos 基础开发环境搭建之Maven私服nexus
- Centos 环境搭建之Maven私服nexus
- 在linux上使用nexus搭建maven私服,详细步骤
- Linux环境使用Nexus搭建Maven私服
- Maven私服Nexus的搭建及使用
- Maven仓库—Nexus环境搭建及使用
- 项目开发环境搭建手记(4.Maven私服Nexus安装及自动部署到Tomcat)
- 项目开发环境搭建手记(4.Maven私服Nexus安装及自动部署到Tomcat)
- 项目开发环境搭建手记(4.Maven私服Nexus安装及自动部署到Tomcat)
- 在CentOS上搭建C开发环境
- 在CentOS上搭建C开发环境
- 在Centos上搭建python开发环境
- centos使用nexus搭建私有maven仓库
- centos 搭建 maven nexus
- 使用Nexus工具搭建maven私服,并在AndroidStudio上引用
- Maven+Nexus+Eclipse 搭建开发环境
- nexus 使用Nexus搭建Maven私服
- 通过ddms无法检查的内存泄漏如何查
- ecshop 关于 preg_replace /e 修饰符不安全的几处改动
- 3.14 MonoForAndroid用户人机界面--控制不同的文字字体
- 硬盘丢失了怎么才能恢复呢丨顶尖数据恢复软件恢复硬盘数据丨
- NGUI中的depth
- 在操作系统Centos 6.3 上使用Nexus 2.8搭建MAVEN私服 及 cloudstack 开发环境
- mysql 将时间戳直接转换成日期时间
- swift 易忽略的笔记 10):Generic
- 通用的Java hashCode重写方案
- 11gR2 RAC RMAN备份问题------手动删除归档日志导致RMAN-06059 ORA-19625
- Android WebView的坑总结
- 2013年进口的乳品不合格
- android textview xml 属性设置
- 一般电脑丢失文件怎么才能迅速恢复丨迅龙数据恢复文件丨