解决 bootjar 增加 manifest 属性的问题
authorTang Cheng <cheng.tang@supwisdom.com>
Wed, 3 Jul 2019 14:34:05 +0000 (22:34 +0800)
committerTang Cheng <cheng.tang@supwisdom.com>
Wed, 3 Jul 2019 14:34:05 +0000 (22:34 +0800)
build.gradle
src/main/resources/META-INF/MANIFEST.MF [deleted file]

index fcabe95..3acdeb0 100644 (file)
@@ -1,4 +1,5 @@
 plugins {
+    id 'java'
     id 'org.springframework.boot'
     id 'org.jetbrains.kotlin.jvm'
     id 'org.jetbrains.kotlin.plugin.jpa'
@@ -22,23 +23,17 @@ repositories {
     mavenCentral()
 }
 
-springBoot {
-    mainClassName = startClass
-}
-
-
 bootJar {
-    launchScript()
     mainClassName = startClass
+    manifest {
+        attributes('Payapi-Version': payapiVersion)
+    }
 }
 
 jar {
     baseName = 'payapi'
-    version = '1'
-    manifest {
-        attributes 'Payapi-Version': payapiVersion
-    }
 }
+
 docker {
     name '172.28.201.70:5000/dali/payapi:' + version
     println(jar.archivePath)
diff --git a/src/main/resources/META-INF/MANIFEST.MF b/src/main/resources/META-INF/MANIFEST.MF
deleted file mode 100644 (file)
index e69de29..0000000