天天看点

Centos7下安装nexus3.x 安装

1.官网下载unix版本

2.上传到linux系统的/usr/目录下

[[email protected] ~]# cd /usr/
[[email protected] usr]# ll           
Centos7下安装nexus3.x 安装

3.解压,并重命名为nexus

[[email protected] usr]# tar -zxvf nexus-3.15.2-01-unix.tar.gz 

[[email protected] usr]# mv nexus-3.15.2-01 nexus           
Centos7下安装nexus3.x 安装
Centos7下安装nexus3.x 安装

4.修改配置修改运行nexus3所使用的用户

[[email protected] usr]# cd nexus/bin/
contrib/         nexus            nexus.rc         nexus.vmoptions  
[[email protected] usr]# cd nexus/bin/
[[email protected] bin]# ll
总用量 32
drwxr-xr-x. 2 root root  4096 4月   4 15:44 contrib
-rwxr-xr-x. 1 root root 17269 1月  26 02:34 nexus
-rw-r--r--. 1 root root    15 1月  26 02:30 nexus.rc
-rw-r--r--. 1 root root   464 1月  26 02:34 nexus.vmoptions
[[email protected] bin]# vi nexus.rc 
[[email protected] bin]# cat nexus.rc           
Centos7下安装nexus3.x 安装

5.修改nexus3启动所使用的jdk版本 

 如果没有配置环境变量需要配置这个路径;

如果有jdk环境变量可以省略

[[email protected] java8]# cd /usr/local/src/nexus/bin/ 
[[email protected] bin]# ls 

[[email protected] bin]# vim nexus 
[[email protected] bin]# cat nexus           
Centos7下安装nexus3.x 安装

6.修改nexus3默认端口

[[email protected] nexus]# cd etc/
[[email protected] etc]# ls
fabric  jetty  karaf  logback  nexus-default.properties  ssl
[[email protected] etc]# cat nexus-default.properties 
           
Centos7下安装nexus3.x 安装

7.修改nexus3数据以及相关日志的存储位置

[[email protected] nexus]# cd bin/
[[email protected] bin]# ls
contrib  nexus  nexus.rc  nexus.vmoptions
[[email protected] bin]# cat nexus.vmoptions
           
Centos7下安装nexus3.x 安装

8.启动nexus

Centos7下安装nexus3.x 安装
[[email protected] bin]# ./nexus start
WARNING: ************************************************************
WARNING: Detected execution as "root" user.  This is NOT recommended!
WARNING: ************************************************************
Starting nexus
           

注意:关闭防火墙访问!!

9.访问

http://IP地址:8081/    使用admin/admin123登陆

Centos7下安装nexus3.x 安装

继续阅读