Centos7安装nexus

来源:互联网 发布:淘宝 zara 原单 编辑:程序博客网 时间:2024/06/05 06:06

1、下载 http://www.sonatype.org/nexus/archived/

2、nexus 名称 nexus-2.12.0-01-bundle.tar.gz ,上传到 /usr/local/java/nexus中。

3、解压  tar zxvf nexus-2.12.0-01-bundle.tar.gz 

4、进入 /usr/local/java/nexus/nexus-2.12.0-01/bin 中,启动nexus;

[root@localhost bin]# ./nexusUsage: ./nexus { console | start | stop | restart | status | dump }[root@localhost bin]# ./nexus start****************************************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.

出现警告,启动失败;

这是要求,配置环境变量;具体步骤如下:

4.1    编辑环境变量

vi /etc/profile

4.2    在最后添加 

############################################################################nexus###############################export RUN_AS_USER=root

4.3  配置环境变量生效

source /etc/profile 

4.4  重新运行 

[root@localhost bin]# source /etc/profile  [root@localhost bin]# ./nexus start****************************************WARNING - NOT RECOMMENDED TO RUN AS ROOT****************************************Starting Nexus OSS...Started Nexus OSS.


5、启动8081端口

 

firewall-cmd   --add-port=8081/tcp

6、访问 http://192.168.1.250:8081/nexus/


首先登陆 nexus,默认的用户名及密码为 admin 和 admin123





原创粉丝点击