springboot 项目打成 jar 包后想修改 jar 包配置文件,用压缩软件手动修改依赖的 jar 包的配置文件报错 Unable to open nested entry It has been compressed and nested jar files must be stored without compression。 应该如何正确的操作。
springboot 项目打成 jar 包后想修改 jar 包配置文件,用压缩软件手动修改依赖的 jar 包的配置文件报错 Unable to open nested entry It has been compressed and nested jar files must be stored without compression。 应该如何正确的操作。
1
armoni Dec 11, 2018
配置文件放 jar 外面
|
2
akiakiseofficial Dec 11, 2018 via iPhone
按我的理解,如果想修改 application.properties 里的配置,应该在运行时手动覆盖,比如我要修改 spring.profiles.active 的值:
java -jar app.jar -Dspring.profiles.active=test 或者重新打包。 用压缩软件修改....感觉不好。 |