Nexus3

下载

wget https://download.sonatype.com/nexus/3/latest-unix.tar.gz
# 应该是被墙了的

部署

  • 安装

yum install -y java-1.8.0-openjdk

mkdir /opt
tar xvf latest-unix.tar.gz -C /opt
mv /opt/lastest-unix /opt/nexus  # nexus执行文件目录
  • 创建运行用户

useradd --system --comment 'nexus' --user-group nexus
  • 修改nexus目录权限

chown -R nexus:nexus /opt/nexus
chown -R nexus:nexus /opt/sonatype-work

开机自启

cat > /etc/systemd/system/nexus.service <<EOF
[Unit]
Description=nexus service
After=network.target
  
[Service]
Type=forking
LimitNOFILE=65536
ExecStart=/opt/nexus/bin/nexus start
ExecStop=/opt/nexus/bin/nexus stop
User=nexus
Restart=on-abort
  
[Install]
WantedBy=multi-user.target
EOF
systemctl daemon-reload
systemctl enable nexus
systemctl start nexus

访问

http://host-IP:8081

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容