Linux系統 安裝maven私有庫教程詳解

linux部署安裝maven私有庫

官網下載地址: http://pan.baidu.com/s/1dFJv5wl

本地下載地址:https://download.csdn.net/download/qq_36961226/13067106

在/usr/etc 目錄下創建   mkdir nexus 文件夾

將安裝包上傳至linux系統 上傳至nexus文件夾內

解壓安裝包

[[email protected] nexus]# tar -zxvf nexus-2.14.8-01-bundle.tar.gz

會解壓出2個文件夾

nexus-2.14.2-01(nexus服務,啓動也是這個)

sonatype-work(私有庫目錄)

進入到   nexus-2.14.8-01/conf/  目錄下  編輯 nexus.properties 文件

[[email protected] nexus]# cd nexus-2.14.8-01/conf/

[[email protected] conf]# vim nexus.properties

application-port=8081(啓動後訪問的端口號,可以自行修改)

application-host=0.0.0.0(訪問限制,0.0.0.0表示任何地址都可以訪問)

我們保持默認不變,繼續。。。

進入到   nexus-2.14.8-01/bin 目錄下    編輯 nexus 文件  

[[email protected] bin]# vim nexus

默認是下面這一條:

# RUN_AS_USER=

修改成:

RUN_AS_USER=root

linux防火牆打開8081端口:

 vi /etc/sysconfig/iptables

重啓防火牆:

 service iptables restart

啓動nexus

nexus-2.14.8-01/bin/nexus start

訪問Nexus

訪問地址:http://192.168.226.130:8081/nexus  注意ip地址是linux系統ip地址