打包配置说明调整

This commit is contained in:
黎润豪 2025-02-27 10:50:47 +08:00
parent 86fdbccfee
commit 1a67b1da72
2 changed files with 3 additions and 0 deletions

BIN
img/SpringBootConfig1.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 94 KiB

View File

@ -62,6 +62,9 @@
> 打包前需确认环境配置(如数据源,外部接口)是否正确。切勿发生将测试环境接入正式环境,导致测试环境向正式环境写数据的情况出现。
> SpringBoot项目一般直接修改yml的引用即可![SpringBoot配置](../img/SpringBootConfig.jpg)
> 如果配置为引用配置,这通常是指服务器已配置了环境变量。当项目启动时,直接取环境变量进行注入判断,因此无需修改,直接打包即可
> ![SpringBoot配置1](../img/SpringBootConfig1.jpg)
#### 打包
> 打包前应先清理maven的class缓存。有时候因为调试过程中的一些编译报错等奇奇怪怪的原因导致maven的class缓存内容不是最新的class。为避免将错误的class文件打包应先对目录进行clean。