From be5923d8ea52b4580c05b4fb76b676f981d9d0da Mon Sep 17 00:00:00 2001 From: lvleigang <957075182@qq.com> Date: Mon, 8 Jul 2024 15:43:36 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8Dwar=E6=89=93=E4=B8=8D?= =?UTF-8?q?=E5=87=BA=E6=9D=A5=E6=9C=AC=E5=9C=B0jar=E7=9A=84=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 26 ++++++++++++++++++ service/pom.xml | 8 +++--- .../lib/DataApiSdk-jar-with-dependencies.jar | Bin .../lib/bcprov-jdk15on-1.57.jar | Bin .../lib/bcprov-jdk15on-1.70.jar | Bin .../lib/pubbaseapp_nccloud_rtLevel-1.jar | Bin .../WEB-INF => resources}/lib/yonyoulog.jar | Bin 7 files changed, 30 insertions(+), 4 deletions(-) rename service/src/main/{webapp/WEB-INF => resources}/lib/DataApiSdk-jar-with-dependencies.jar (100%) rename service/src/main/{webapp/WEB-INF => resources}/lib/bcprov-jdk15on-1.57.jar (100%) rename service/src/main/{webapp/WEB-INF => resources}/lib/bcprov-jdk15on-1.70.jar (100%) rename service/src/main/{webapp/WEB-INF => resources}/lib/pubbaseapp_nccloud_rtLevel-1.jar (100%) rename service/src/main/{webapp/WEB-INF => resources}/lib/yonyoulog.jar (100%) diff --git a/pom.xml b/pom.xml index afe24610..543edbed 100644 --- a/pom.xml +++ b/pom.xml @@ -411,6 +411,32 @@ <skip>true</skip> </configuration> </plugin> + <plugin> + <!--设置maven-war-plugins插件,否则外部依赖无法打进war包--> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-surefire-plugin</artifactId> + <version>2.18.1</version> + <configuration> + <skipTests>true</skipTests> + </configuration> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-war-plugin</artifactId> + <configuration> + <webResources> + <resource> + <directory>${basedir}/../service/src/main/resources/lib</directory> + <targetPath>WEB-INF/lib/</targetPath> + <filtering>false</filtering> + <includes> + <!-- 匹配所有jar包 --> + <include>**/*.jar</include> + </includes> + </resource> + </webResources> + </configuration> + </plugin> </plugins> <!--加载src/main/java下的xml--> <resources> diff --git a/service/pom.xml b/service/pom.xml index 0a7f3138..d47eef74 100644 --- a/service/pom.xml +++ b/service/pom.xml @@ -26,14 +26,14 @@ <artifactId>pubbaseapp_nccloud_rtLevel</artifactId> <version>1</version> <scope>system</scope> - <systemPath>${basedir}/src/main/webapp/WEB-INF/lib/pubbaseapp_nccloud_rtLevel-1.jar</systemPath> + <systemPath>${basedir}/src/main/resources/lib/pubbaseapp_nccloud_rtLevel-1.jar</systemPath> </dependency> <dependency> <groupId>com.hzya.bipyonyoulog</groupId> <artifactId>yonyoulog</artifactId> <version>1</version> <scope>system</scope> - <systemPath>${basedir}/src/main/webapp/WEB-INF/lib/yonyoulog.jar</systemPath> + <systemPath>${basedir}/src/main/resources/lib/yonyoulog.jar</systemPath> </dependency> <dependency> @@ -41,7 +41,7 @@ <artifactId>bcprov</artifactId> <version>1</version> <scope>system</scope> - <systemPath>${basedir}/src/main/webapp/WEB-INF/lib/bcprov-jdk15on-1.70.jar</systemPath> + <systemPath>${basedir}/src/main/resources/lib/bcprov-jdk15on-1.70.jar</systemPath> </dependency> <dependency> @@ -49,7 +49,7 @@ <artifactId>DataApiSdk</artifactId> <version>1</version> <scope>system</scope> - <systemPath>${basedir}/src/main/webapp/WEB-INF/lib/DataApiSdk-jar-with-dependencies.jar</systemPath> + <systemPath>${basedir}/src/main/resources/lib/DataApiSdk-jar-with-dependencies.jar</systemPath> </dependency> </dependencies> <build> diff --git a/service/src/main/webapp/WEB-INF/lib/DataApiSdk-jar-with-dependencies.jar b/service/src/main/resources/lib/DataApiSdk-jar-with-dependencies.jar similarity index 100% rename from service/src/main/webapp/WEB-INF/lib/DataApiSdk-jar-with-dependencies.jar rename to service/src/main/resources/lib/DataApiSdk-jar-with-dependencies.jar diff --git a/service/src/main/webapp/WEB-INF/lib/bcprov-jdk15on-1.57.jar b/service/src/main/resources/lib/bcprov-jdk15on-1.57.jar similarity index 100% rename from service/src/main/webapp/WEB-INF/lib/bcprov-jdk15on-1.57.jar rename to service/src/main/resources/lib/bcprov-jdk15on-1.57.jar diff --git a/service/src/main/webapp/WEB-INF/lib/bcprov-jdk15on-1.70.jar b/service/src/main/resources/lib/bcprov-jdk15on-1.70.jar similarity index 100% rename from service/src/main/webapp/WEB-INF/lib/bcprov-jdk15on-1.70.jar rename to service/src/main/resources/lib/bcprov-jdk15on-1.70.jar diff --git a/service/src/main/webapp/WEB-INF/lib/pubbaseapp_nccloud_rtLevel-1.jar b/service/src/main/resources/lib/pubbaseapp_nccloud_rtLevel-1.jar similarity index 100% rename from service/src/main/webapp/WEB-INF/lib/pubbaseapp_nccloud_rtLevel-1.jar rename to service/src/main/resources/lib/pubbaseapp_nccloud_rtLevel-1.jar diff --git a/service/src/main/webapp/WEB-INF/lib/yonyoulog.jar b/service/src/main/resources/lib/yonyoulog.jar similarity index 100% rename from service/src/main/webapp/WEB-INF/lib/yonyoulog.jar rename to service/src/main/resources/lib/yonyoulog.jar