linux下nexus+maven
来源:互联网 发布:sql联合主键语句 编辑:程序博客网 时间:2024/05/20 07:53
1、https://www.sonatype.com/download-oss-sonatype下载2.14 tar.gz文件(3.0需要JDK8以上)
2、上传安装包到linux目录下
3、解压tar zxvf nexus-2.14.1-01-bundle.tar.gz
4、进入bin目录下,输入./nexus start(root用户会出现以下问题,设置步骤参考步骤5)
****************************************
WARNING - NOT RECOMMENDED TO RUN AS ROOT
****************************************
If you insist running as root, then set the environment variable RUN_AS_USER=root before running this script.
5、进入/etc/profile修改环境变量export RUN_AS_USER=root
6、source profile使设置生效
7、进入nexus的bin目录,./nexus start
****************************************
WARNING - NOT RECOMMENDED TO RUN AS ROOT
****************************************
Starting Nexus OSS...
Started Nexus OSS.
8、http://服务器IP:8081/nexus/(默认端口是8081)修改端口号:进入conf目录,修改nexus.properties的端口
9、登录,默认用户名admin 密码admin23
10、上传jar包到私服
11、配置仓库信息
<repositories> <repository> <id>public</id> 与nexus的仓库名对应(可通过nexus仓库列表,查看configuration配置找到ID) <name>Public Repositories</name> <url>http://IP:8081/nexus/content/groups/public/</url> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>true</enabled> </snapshots> </repository> </repositories> <pluginRepositories> <pluginRepository> <id>public</id> <name>Public Repositories</name> <url>http://IP:8081/nexus/content/groups/public/</url> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>true</enabled> </snapshots> </pluginRepository> </pluginRepositories>
<!-- 自动打包 通过jenkins上传-->
<distributionManagement>
<repository>
<id>releases</id><!--这个ID需要与你的release仓库的Repository ID一致-->
<url>http://xxx.xx.xx.xx:8081/nexus/content/repositories/releases</url>
</repository>
<snapshotRepository>
<id>snapshots</id><!--这个ID需要与你的snapshots仓库的Repository ID一致-->
<url>http://xxx.xx.xx.xx:8081/nexus/content/repositories/snapshots</url>
</snapshotRepository>
</distributionManagement>
12、设置deploy账户密码
security-users-右键deployment
13、部署maven:
将linux安装包上传到文件夹
tat -zvxf 安装文件名
配置conf目录下的setting.xml文件:
在<settings><profiles></profiles></settings>节点之间添加配置:
接着在<settings></settings>节点之间添加配置:
<server>
<id>public</id>与仓库地址ID一致
<username>deployment</username>
<password>123456</password><!--这个密码就是你设置的密码-->
</server>
<id>releases</id>
<username>deployment</username>
<password>123456</password><!--这个密码就是你设置的密码-->
</server>
<server>
<id>snapshots</id>
<username>deployment</username>
<password>123456</password><!--这个密码就是你设置的密码-->
</server>
以上配置好了连接Nexus私服。
14、运行发布控制台mvn clean deploy
- linux下nexus+maven
- Linux下搭建maven服务器nexus
- maven-02-linux 下安装nexus
- Linux下使用nexus搭建maven私服
- Linux下使用nexus搭建maven私服
- Linux下使用nexus搭建maven私服
- Linux下使用nexus搭建maven私服
- Linux下使用Nexus搭建Maven私服
- Linux下使用nexus搭建maven私服
- Linux下安装maven和nexus
- Linux下使用Nexus搭建Maven私服
- linux下 nexus搭建maven私有库 自动打包
- linux下nexus搭建maven私有库自动打包
- windows和linux 下搭建maven 私库 nexus
- Linux下 nexus搭建maven私有库 自动打包
- Linux下搭建maven-nexus私服仓库
- linux下 nexus搭建maven私有库 自动打包
- Linux环境下使用Nexus搭建maven私服
- Linux下chkconfig命令详解
- sprintf
- 关于 mongod 的安装,启动
- _endCellAnimationsWithContext报错解决
- Mysql 基础操作教程
- linux下nexus+maven
- Primavera P6EPPM授权应关注点
- AngularJS(四)_作用域$scope
- 构建wifi破解所需的密码库文件
- RecyclerView+SwipeRefreshLayout实现上拉刷新,下拉加载更多的功能
- Android计步器的实现(1)
- 面试题总结
- 深度学习基础介绍:机器学习介绍和基本概念
- 翻转链表