运行jar包,加载外部配置文件
加载外部配置文件
当配置文件需要修改时,需要重新打包项目太麻烦
通过加载外部配置文件更方便 spring.config.location=外部配置文件地址
nohup java -jar blog-springboot-0.0.1.jar --spring.config.location=blog-application.yml >/dev/null 2>&1 &
当配置文件需要修改时,需要重新打包项目太麻烦
通过加载外部配置文件更方便 spring.config.location=外部配置文件地址
nohup java -jar blog-springboot-0.0.1.jar --spring.config.location=blog-application.yml >/dev/null 2>&1 &