Windows安装配置Nexus3.6与Maven3.3.9配置

2023-10-21 06:48

本文主要是介绍Windows安装配置Nexus3.6与Maven3.3.9配置,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

1.编写目录

用于描述Nexus服务器搭建与maven使用

2.Nexus私服搭建

  1. 环境准备
    需要安装JDK1.8版本并配置环境变量

  2. 官网地址
    https://www.sonatype.com/download-oss-sonatype

  3. 下载
    nexus官网下载截图

  4. 下载后解压(注意,路径不要带空格及中文)

    nexus解压目录
    nexus-3.6.2-01:安装文件
    sonatype-work:工作目录

  5. 安装完成
    默认端口:8081
    默认帐号:admin
    默认密码:admin123

  6. 启动nexus
    在命令行进入nexus-3.6.2-01/bin目录下输入:nexus /run
    首次启动比较慢

    这里写图片描述

    启动成功:

    这里写图片描述

  7. 访问地址
    http://localhost:8081

    这里写图片描述

  8. 修改IP和端口
    修改nexus-3.6.2-01/etc/nexus-default.properties文件

3.Maven配置

pom.xml

    <distributionManagement><repository><id>nexus-releases</id><name>Nexus Release Repository</name><url>http://localhost:8081/repository/maven-releases/</url></repository><snapshotRepository><id>nexus-snapshots</id><name>Nexus Snapshot Repository</name><url>http://localhost:8081/repository/maven-snapshots/</url></snapshotRepository></distributionManagement>

conf.xml

<localRepository>C:/java/mavenRepository</localRepository>
<server><id>nexus-releases</id><username>admin</username><password>admin123</password>
</server>
<server><id>nexus-snapshots</id><username>admin</username><password>admin123</password>
</server>
<mirror><id>nexus-releases</id><mirrorOf>*</mirrorOf><url>http://localhost:8081/repository/maven-public/</url>
</mirror>
<mirror><id>nexus-snapshots</id><mirrorOf>*</mirrorOf><url>http://localhost:8081/repository/maven-public/</url>
</mirror>
<profile><id>nexus</id><repositories><repository><id>nexus-releases</id><url>http://nexus-releases</url><releases><enabled>true</enabled></releases><snapshots><enabled>true</enabled></snapshots></repository><repository><id>nexus-snapshots</id><url>http://nexus-snapshots</url><releases><enabled>true</enabled></releases><snapshots><enabled>true</enabled></snapshots></repository></repositories><pluginRepositories><pluginRepository><id>nexus-releases</id><url>http://nexus-releases</url><releases><enabled>true</enabled></releases><snapshots><enabled>true</enabled></snapshots></pluginRepository><pluginRepository><id>nexus-snapshots</id><url>http://nexus-snapshots</url><releases><enabled>true</enabled></releases><snapshots><enabled>true</enabled></snapshots></pluginRepository></pluginRepositories>
</profile>
<activeProfiles>
<activeProfile>nexus</activeProfile>
</activeProfiles>

这篇关于Windows安装配置Nexus3.6与Maven3.3.9配置的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/252646

相关文章

VSCode中配置node.js的实现示例

《VSCode中配置node.js的实现示例》本文主要介绍了VSCode中配置node.js的实现示例,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着... 目录一.node.js下载安装教程二.配置npm三.配置环境变量四.VSCode配置五.心得一.no

debian12安装docker的实现步骤

《debian12安装docker的实现步骤》本文主要介绍了debian12安装docker的实现步骤,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着... 目录步骤 1:更新你的系统步骤 2:安装依赖项步骤 3:添加 docker 的官方 GPG 密钥步骤

Python+Tkinter实现Windows Hosts文件编辑管理工具

《Python+Tkinter实现WindowsHosts文件编辑管理工具》在日常开发和网络调试或科学上网场景中,Hosts文件修改是每个开发者都绕不开的必修课,本文将完整解析一个基于Python... 目录一、前言:为什么我们需要专业的Hosts管理工具二、工具核心功能全景图2.1 基础功能模块2.2 进

Gradle在国内配置镜像加速的实现步骤

《Gradle在国内配置镜像加速的实现步骤》在国内使用Gradle构建项目时,最大的痛点就是依赖下载贼慢,甚至卡死,下面教你如何配置国内镜像加速Gradle下载依赖,主要是通过改写repositori... 目录引言一、修改 build.gradle 或 settings.gradle 的 reposito

使用easy connect之后,maven无法使用,原来需要配置-Djava.net.preferIPv4Stack=true问题

《使用easyconnect之后,maven无法使用,原来需要配置-Djava.net.preferIPv4Stack=true问题》:本文主要介绍使用easyconnect之后,maven无法... 目录使用easGWowCy connect之后,maven无法使用,原来需要配置-DJava.net.pr

Python+PyQt5开发一个Windows电脑启动项管理神器

《Python+PyQt5开发一个Windows电脑启动项管理神器》:本文主要介绍如何使用PyQt5开发一款颜值与功能并存的Windows启动项管理工具,不仅能查看/删除现有启动项,还能智能添加新... 目录开篇:为什么我们需要启动项管理工具功能全景图核心技术解析1. Windows注册表操作2. 启动文件

史上最全nginx详细参数配置

《史上最全nginx详细参数配置》Nginx是一个轻量级高性能的HTTP和反向代理服务器,同时也是一个通用代理服务器(TCP/UDP/IMAP/POP3/SMTP),最初由俄罗斯人IgorSyso... 目录基本命令默认配置搭建站点根据文件类型设置过期时间禁止文件缓存防盗链静态文件压缩指定定错误页面跨域问题

nginx负载均衡及详细配置方法

《nginx负载均衡及详细配置方法》Nginx作为一种高效的Web服务器和反向代理服务器,广泛应用于网站的负载均衡中,:本文主要介绍nginx负载均衡及详细配置,需要的朋友可以参考下... 目录一、 nginx负载均衡策略1.1 基本负载均衡策略1.2 第三方策略1.3 策略对比二、 nginx配置2.1

使用Python创建一个功能完整的Windows风格计算器程序

《使用Python创建一个功能完整的Windows风格计算器程序》:本文主要介绍如何使用Python和Tkinter创建一个功能完整的Windows风格计算器程序,包括基本运算、高级科学计算(如三... 目录python实现Windows系统计算器程序(含高级功能)1. 使用Tkinter实现基础计算器2.

Android开发环境配置避坑指南

《Android开发环境配置避坑指南》本文主要介绍了Android开发环境配置过程中遇到的问题及解决方案,包括VPN注意事项、工具版本统一、Gerrit邮箱配置、Git拉取和提交代码、MergevsR... 目录网络环境:VPN 注意事项工具版本统一:android Studio & JDKGerrit的邮