美文网首页
CentOS7下安装Nexus

CentOS7下安装Nexus

作者: 笑Skr人啊 | 来源:发表于2020-03-19 14:32 被阅读0次

1 安装(保证JDK已安装且配置环境变量)

1.1 下载解压

# 创建目录
[root@gp6 soft]# mkdir nexus

# 进入目录
[root@gp6 soft]# cd nexus/

# 将文件上传至该目录下
[root@gp6 nexus]# rz

# 解压
[root@gp6 nexus]# tar -zxvf nexus-2.11.2-03-bundle.tar.gz 

# 解压后目录
[root@gp6 nexus]# ll
总用量 69144
drwxr-xr-x. 8 root root     4096 2月  13 2015 nexus-2.11.2-03
-rw-r--r--. 1 root root 70793720 8月  12 10:37 nexus-2.11.2-03-bundle.tar.gz
drwxr-xr-x. 3 root root     4096 2月  13 2015 sonatype-work

# 进入nexus目录
[root@gp6 nexus]# cd nexus-2.11.2-03/

# 配置端口和 work 目录信息(视具体情况修改,此处保留默认,未作修改)
[root@gp6 nexus-2.11.2-03]# vi ./conf/nexus.properties 
...
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


# 编辑 nexus 脚本, 配置 RUN_AS_USER 参数(RUN_AS_USER=root)
[root@gp6 nexus-2.11.2-03]# vi ./bin/nexus
...
RUN_AS_USER=root
...

# 启动nexus(启动前,将端口开放或者直接关闭防火墙)
[root@gp6 nexus-2.11.2-03]# ./bin/nexus start
****************************************
WARNING - NOT RECOMMENDED TO RUN AS ROOT
****************************************
Starting Nexus OSS...
Started Nexus OSS.

# 查看启动状态
[root@gp6 nexus-2.11.2-03]# ./bin/nexus status
****************************************
WARNING - NOT RECOMMENDED TO RUN AS ROOT
****************************************
Nexus OSS is running (3241).

2 配置

2.1 进入Nexus可视化页面

ip:8081/nexus

例:
http://192.168.56.101:8081/nexus
image.png

2.2 登录

默认账号: admin
密码: admin123

2.3 修改用户邮箱与密码

修改邮箱 修改密码

相关文章

网友评论

      本文标题:CentOS7下安装Nexus

      本文链接:https://www.haomeiwen.com/subject/kcclyhtx.html