1 下载maven

官网下载 本人下载的是apache-maven-3.6.0-bin.tar.gz

2 解压压缩文件到 /opt 文件夹下

tar zxvf apache-maven-3.6.0-bin.tar.gz –C /opt

3 配置环境变量

vim  /etc/profile

MAVEN_HOME=/opt/maven-3.6.0

export PATH=$PATH:$MAVEN_HOME/bin

生效环境变量

source  /etc/profile

 

3 设置aliyunmaven仓库加速

 

conf/settings.xml

配置

~~~

<mirrors>
     <mirror>
        <id>aliyunmaven</id>
        <mirrorOf>*</mirrorOf>
        <name>阿里云公共仓库</name>
        <url>https://maven.aliyun.com/repository/public</url>
    </mirror>
  </mirrors>

~~~

相关文章:

  • 2022-01-08
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-05
  • 2021-11-28
  • 2021-12-12
猜你喜欢
  • 2021-06-25
  • 2021-07-12
  • 2021-12-10
  • 2021-07-23
  • 2021-08-23
  • 2021-12-15
  • 2021-06-02
相关资源
相似解决方案