|
@ -200,19 +200,83 @@
|
|
|
<finalName>svr-internet-hospital-entrance</finalName>
|
|
|
<plugins>
|
|
|
<plugin>
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
<artifactId>maven-jar-plugin</artifactId>
|
|
|
<configuration>
|
|
|
<mainClass>com.yihu.SvrInternetHospitalEntranceApplication</mainClass>
|
|
|
<archive>
|
|
|
<!-- 生成的jar中,不要包含pom.xml和pom.properties这两个文件 -->
|
|
|
<addMavenDescriptor>false</addMavenDescriptor>
|
|
|
<manifest>
|
|
|
<!-- 是否要把第三方jar加入到类构建路径 -->
|
|
|
<addClasspath>true</addClasspath>
|
|
|
<!-- 外部依赖jar包的最终位置 -->
|
|
|
<classpathPrefix>lib/</classpathPrefix>
|
|
|
<mainClass>com.yihu.SvrInternetHospitalEntranceApplication</mainClass>
|
|
|
</manifest>
|
|
|
</archive>
|
|
|
</configuration>
|
|
|
</plugin>
|
|
|
<!--拷贝依赖到jar外面的lib目录-->
|
|
|
<plugin>
|
|
|
<artifactId>maven-war-plugin</artifactId>
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
<artifactId>maven-dependency-plugin</artifactId>
|
|
|
<executions>
|
|
|
<execution>
|
|
|
<id>copy-lib</id>
|
|
|
<phase>package</phase>
|
|
|
<goals>
|
|
|
<goal>copy-dependencies</goal>
|
|
|
</goals>
|
|
|
<configuration>
|
|
|
<!-- 依赖包输出目录,将来不打进jar包里 -->
|
|
|
<outputDirectory>${project.build.directory}/lib</outputDirectory>
|
|
|
<excludeTransitive>false</excludeTransitive>
|
|
|
<stripVersion>false</stripVersion>
|
|
|
<includeScope>runtime</includeScope>
|
|
|
</configuration>
|
|
|
</execution>
|
|
|
</executions>
|
|
|
</plugin>
|
|
|
<!--指定配置文件,将resources打成外部resource-->
|
|
|
<plugin>
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
<artifactId>maven-jar-plugin</artifactId>
|
|
|
<configuration>
|
|
|
<failOnMissingWebXml>false</failOnMissingWebXml>
|
|
|
<filteringDeploymentDescriptors>true</filteringDeploymentDescriptors>
|
|
|
<archive>
|
|
|
<!-- 指定配置文件目录,这样jar运行时会去找到同目录下的resources文件夹下查找 -->
|
|
|
<manifestEntries>
|
|
|
<Class-Path>resources/</Class-Path>
|
|
|
</manifestEntries>
|
|
|
</archive>
|
|
|
<!-- 打包时忽略的文件(也就是不打进jar包里的文件) -->
|
|
|
<excludes>
|
|
|
<exclude>**/*.yml</exclude>
|
|
|
<exclude>**/*.xml</exclude>
|
|
|
</excludes>
|
|
|
</configuration>
|
|
|
</plugin>
|
|
|
<!-- 拷贝资源文件 外面的resource目录-->
|
|
|
<plugin>
|
|
|
<artifactId>maven-resources-plugin</artifactId>
|
|
|
<executions>
|
|
|
<execution>
|
|
|
<id>copy-dependencies</id>
|
|
|
<phase>package</phase>
|
|
|
<goals>
|
|
|
<goal>copy-resources</goal>
|
|
|
</goals>
|
|
|
<configuration>
|
|
|
<!-- 资源文件输出目录 -->
|
|
|
<outputDirectory>${project.build.directory}/resources</outputDirectory>
|
|
|
<resources>
|
|
|
<resource>
|
|
|
<directory>src/main/resources</directory>
|
|
|
</resource>
|
|
|
</resources>
|
|
|
</configuration>
|
|
|
</execution>
|
|
|
</executions>
|
|
|
</plugin>
|
|
|
</plugins>
|
|
|
|
|
|
<resources>
|