1
|
cd /home |
1
|
wget https://github.com/spring-projects/spring-boot/archive/vx.x.x.RELEASE.tar.gz --no-check-certificate |
也可通过本地浏览器下载源码后,上传至服务器“home”目录。
1
|
tar -zxvf vx.x.x.RELEASE.tar.gz |
1
|
mv spring-boot-x.x.x.RELEASE spring-boot && cd spring-boot |
1
|
cd spring-boot-project/spring-boot |
1
|
vim pom.xml
|
1 2 3 4 5 6 7 8 9 10 11 12 13 |
<dependency> <groupId>io.netty</groupId> <artifactId>netty-transport-native-epoll</artifactId> <version>4.1.43.Final</version> <classifier>linux-aarch_64</classifier> <scope>compile</scope> <exclusions> <exclusion> <artifactId>commons-logging</artifactId> <groupId>commons-logging</groupId> </exclusion> </exclusions> </dependency> |
1 2 3 4 5 6 |
<exclusions> <exclusion> <groupId>io.netty</groupId> <artifactId>netty-transport-native-epoll</artifactId> </exclusion> </exclusions> |
1 2 3 4 5 6 |
<exclusions> <exclusion> <groupId>io.projectreactor.netty</groupId> <artifactId>reactor-netty</artifactId> </exclusion> </exclusions> |
1
|
cd ../spring-boot-starters/spring-boot-starter-webflux/ |
1
|
vim pom.xml
|
1 2 3 4 5 6 |
<exclusions> <exclusion> <groupId>io.netty</groupId> <artifactId>netty-transport-native-epoll</artifactId> </exclusion> </exclusions> |
1
|
cd ../spring-boot-starter-artemis |
1
|
vim pom.xml
|
1 2 3 4 |
<exclusion> <groupId>io.netty</groupId> <artifactId>netty-transport-native-epoll</artifactId> </exclusion> |
1
|
cd ../spring-boot-starter-rsocket |
1
|
vim pom.xml
|
1 2 3 4 5 6 |
<exclusions> <exclusion> <groupId>io.netty</groupId> <artifactId>netty-transport-native-epoll</artifactId> </exclusion> </exclusions> |
若机器需配置代理才可访问外网,则需要配置Cntlm,参考配置Cntlm。
1 2 |
mkdir -p /root/.m2/repository/io/netty/netty-transport-native-epoll/4.1.43.Final mkdir -p /root/.m2/repository/io/netty/netty-transport-native-epoll/4.1.48.Final |
1 2 |
wget https://mirrors.huaweicloud.com/kunpeng/maven/io/netty/netty-transport-native-epoll/4.1.43.Final/netty-transport-native-epoll-4.1.43.Final-linux-aarch_64.jar --no-check-certificate wget https://mirrors.huaweicloud.com/kunpeng/maven/io/netty/netty-transport-native-epoll/4.1.48.Final/netty-transport-native-epoll-4.1.48.Final.jar --no-check-certificate |
1 2 |
mv netty-transport-native-epoll-4.1.43.Final-linux-aarch_64.jar /root/.m2/repository/io/netty/netty-transport-native-epoll/4.1.43.Final mv netty-transport-native-epoll-4.1.48.Final.jar /root/.m2/repository/io/netty/netty-transport-native-epoll/4.1.48.Final |
1 2 |
cd /home/spring-boot mvn clean install |
若编译过程中产生报错,请根据报错信息并参考故障排除解决,解决完成后需重新如下执行编译安装命令。
1
|
mvn spring-javaformat:apply clean install |
如果Java文件(*.java)被修改过,则编译安装命令中需要增加编译参数:spring-javaformat:apply。