diff --git a/src/main/java/org/wfc/common/license/controller/LicenseCreatorController.java b/src/main/java/org/wfc/common/license/controller/LicenseCreatorController.java index a463662..a68be33 100644 --- a/src/main/java/org/wfc/common/license/controller/LicenseCreatorController.java +++ b/src/main/java/org/wfc/common/license/controller/LicenseCreatorController.java @@ -34,6 +34,9 @@ public class LicenseCreatorController { @Value("${license.licensePath}") private String licensePath; + @Value("${license.privateKeysPath}") + private String privateKeysPath; + /** * 获取服务器硬件信息 * @@ -110,7 +113,7 @@ public class LicenseCreatorController { } // 相对路径resources资源目录 // String resourcePath = getClass().getClassLoader().getResource("").getPath(); - param.setPrivateKeysStorePath("/opt/license/keystore/privateKeys.keystore"); + param.setPrivateKeysStorePath(licensePath); // param.setPrivateKeysStorePath("D:\\projects\\testdir\\spring-boot2-license\\cloud-license-serve\\target\\classes\\privateCerts.keystore"); param.setIssuedTime(new Date()); param.setExpiryTime(genParam.getExpiryTime()); diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties index 64f8cae..74b5348 100644 --- a/src/main/resources/application.properties +++ b/src/main/resources/application.properties @@ -6,5 +6,6 @@ server.shutdown=graceful spring.lifecycle.timeout-per-shutdown-phase=10s #License������� +license.privateKeysPath=/opt/license/keystore/privateKeys.keystore license.licensePath=/opt/license/license.lic