9、Nexus搭建
#1、下載 nexus-latest-bundle.tar.gz 壓縮包放到/home/download 目錄下
#2、解壓nexus壓縮包(使用普通用戶,不建議root)
[root@localhost opt]# su rogue
[rogue@localhost ~]# tar -zxvf /home/download/nexus-latest-bundle.tar.gz -C /opt
#3、啓動nexus
進入nexus的bin目錄下啓動
[rogue@localhost ~]$ cd /opt/nexus-2.11.2-03/bin/
[rogue@localhost bin]$ ./nexus start
Starting Nexus OSS...
Started Nexus OSS.
#4、訪問nexus的web控制檯
訪問地址:http://192.168.1.110:8081 ,然後登錄,默認賬號:admin 密碼:admin123下
最主要的幾個倉庫
修改Apache Snapshots和Central
這是nexus就會到遠程倉庫下載相應的jar包。
nexus相關屬性配置文件是conf目錄下的nexus.properties,如下:
# Sonatype Nexus
# ==============
# This is the most basic configuration of Nexus.
# Jetty section
application-port=8081 //可以在這裏修改訪問端口
application-host=0.0.0.0
nexus-webapp=${bundleBasedir}/nexus
nexus-webapp-context-path=/nexus
# Nexus section
nexus-work=${bundleBasedir}/../sonatype-work/nexus
runtime=${bundleBasedir}/nexus/WEB-INF