pom.xml 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  5. <modelVersion>4.0.0</modelVersion>
  6. <parent>
  7. <groupId>com.yihu.jw</groupId>
  8. <artifactId>wlyy-parent-pom</artifactId>
  9. <version>2.4.0</version>
  10. <relativePath>../../wlyy-parent-pom/pom.xml</relativePath>
  11. </parent>
  12. <artifactId>svr-resource</artifactId>
  13. <!--<packaging>${packaging.type}</packaging>
  14. <packaging>war</packaging>-->
  15. <packaging>jar</packaging>
  16. <version>${project.parent.version}</version>
  17. <properties>
  18. <wagonServerId>192.168.1.220</wagonServerId>
  19. <wagonUrl>scp://sand:timeneverstop@192.168.1.221/home/sand/ehr-release</wagonUrl>
  20. </properties>
  21. <dependencies>
  22. <!-- 支持Tomcat启动 -->
  23. <dependency>
  24. <groupId>org.springframework.boot</groupId>
  25. <artifactId>spring-boot-starter-web</artifactId>
  26. <exclusions>
  27. <exclusion>
  28. <groupId>org.springframework.boot</groupId>
  29. <artifactId>spring-boot-starter-tomcat</artifactId>
  30. </exclusion>
  31. </exclusions>
  32. </dependency>
  33. <dependency>
  34. <groupId>org.springframework.boot</groupId>
  35. <artifactId>spring-boot-starter-tomcat</artifactId>
  36. <scope>provided</scope>
  37. </dependency>
  38. <dependency>
  39. <groupId>javax.servlet</groupId>
  40. <artifactId>javax.servlet-api</artifactId>
  41. </dependency>
  42. <dependency>
  43. <groupId>org.apache.tomcat.embed</groupId>
  44. <artifactId>tomcat-embed-jasper</artifactId>
  45. </dependency>
  46. <!-- true -->
  47. <dependency>
  48. <groupId>org.springframework.boot</groupId>
  49. <artifactId>spring-boot-starter-test</artifactId>
  50. <scope>test</scope>
  51. </dependency>
  52. <dependency>
  53. <groupId>org.springframework.cloud</groupId>
  54. <artifactId>spring-cloud-starter-openfeign</artifactId>
  55. </dependency>
  56. <dependency>
  57. <groupId>org.springframework.cloud</groupId>
  58. <artifactId>spring-cloud-starter-config</artifactId>
  59. <scope>${dependency.scope}</scope>
  60. </dependency>
  61. <dependency>
  62. <groupId>org.springframework.cloud</groupId>
  63. <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
  64. </dependency>
  65. <dependency>
  66. <groupId>org.springframework.boot</groupId>
  67. <artifactId>spring-boot-starter-actuator</artifactId>
  68. </dependency>
  69. <dependency>
  70. <groupId>javax.servlet</groupId>
  71. <artifactId>javax.servlet-api</artifactId>
  72. <scope>${dependency.scope}</scope>
  73. </dependency>
  74. <dependency>
  75. <groupId>com.yihu.jw</groupId>
  76. <artifactId>commons-ehr-constants</artifactId>
  77. <scope>compile</scope>
  78. </dependency>
  79. <dependency>
  80. <groupId>com.yihu.jw</groupId>
  81. <artifactId>mysql-starter</artifactId>
  82. <version>${version.wlyy-common}</version>
  83. </dependency>
  84. <dependency>
  85. <groupId>com.yihu.jw</groupId>
  86. <artifactId>commons-util</artifactId>
  87. <scope>compile</scope>
  88. </dependency>
  89. <dependency>
  90. <groupId>com.yihu.jw</groupId>
  91. <artifactId>commons-data-mysql</artifactId>
  92. <scope>compile</scope>
  93. </dependency>
  94. <dependency>
  95. <groupId>com.yihu.jw</groupId>
  96. <artifactId>commons-rest-model</artifactId>
  97. <scope>compile</scope>
  98. </dependency>
  99. <dependency>
  100. <groupId>com.yihu.jw</groupId>
  101. <artifactId>commons-data-redis</artifactId>
  102. <scope>compile</scope>
  103. </dependency>
  104. <dependency>
  105. <groupId>com.yihu.jw</groupId>
  106. <artifactId>commons-ui-swagger</artifactId>
  107. <scope>compile</scope>
  108. </dependency>
  109. <dependency>
  110. <groupId>com.yihu.jw</groupId>
  111. <artifactId>commons-web</artifactId>
  112. <scope>compile</scope>
  113. </dependency>
  114. <dependency>
  115. <groupId>com.yihu.jw</groupId>
  116. <artifactId>commons-data-solr</artifactId>
  117. <scope>compile</scope>
  118. </dependency>
  119. <dependency>
  120. <groupId>org.springframework.data</groupId>
  121. <artifactId>spring-data-solr</artifactId>
  122. </dependency>
  123. <!-- <dependency>
  124. <groupId>com.yihu.jw</groupId>
  125. <artifactId>commons-entity</artifactId>
  126. </dependency>-->
  127. <dependency>
  128. <groupId>com.yihu.jw</groupId>
  129. <artifactId>commons-profile-core</artifactId>
  130. <scope>compile</scope>
  131. </dependency>
  132. <dependency>
  133. <groupId>com.yihu.jw</groupId>
  134. <artifactId>commons-data-hbase</artifactId>
  135. <scope>compile</scope>
  136. </dependency>
  137. <dependency>
  138. <groupId>com.yihu.jw</groupId>
  139. <artifactId>commons-data-query</artifactId>
  140. <scope>compile</scope>
  141. </dependency>
  142. <dependency>
  143. <groupId>com.yihu.jw</groupId>
  144. <artifactId>commons-data-fastdfs</artifactId>
  145. <scope>compile</scope>
  146. </dependency>
  147. <dependency>
  148. <groupId>com.yihu.jw</groupId>
  149. <artifactId>commons-data-elasticsearch</artifactId>
  150. <version>2.4.0</version>
  151. </dependency>
  152. <dependency>
  153. <groupId>org.quartz-scheduler</groupId>
  154. <artifactId>quartz</artifactId>
  155. <scope>${dependency.scope}</scope>
  156. </dependency>
  157. <dependency>
  158. <groupId>com.alibaba</groupId>
  159. <artifactId>fastjson</artifactId>
  160. </dependency>
  161. </dependencies>
  162. <build>
  163. <finalName>svr-resource</finalName>
  164. <plugins>
  165. <plugin>
  166. <groupId>org.apache.maven.plugins</groupId>
  167. <artifactId>maven-jar-plugin</artifactId>
  168. <configuration>
  169. <archive>
  170. <!-- 生成的jar中,不要包含pom.xml和pom.properties这两个文件 -->
  171. <addMavenDescriptor>false</addMavenDescriptor>
  172. <manifest>
  173. <!-- 是否要把第三方jar加入到类构建路径 -->
  174. <addClasspath>true</addClasspath>
  175. <!-- 外部依赖jar包的最终位置 -->
  176. <classpathPrefix>lib/</classpathPrefix>
  177. <mainClass>com.yihu.jw.ResourceSvrApp</mainClass>
  178. </manifest>
  179. </archive>
  180. </configuration>
  181. </plugin>
  182. <!--拷贝依赖到jar外面的lib目录-->
  183. <plugin>
  184. <groupId>org.apache.maven.plugins</groupId>
  185. <artifactId>maven-dependency-plugin</artifactId>
  186. <executions>
  187. <execution>
  188. <id>copy-lib</id>
  189. <phase>package</phase>
  190. <goals>
  191. <goal>copy-dependencies</goal>
  192. </goals>
  193. <configuration>
  194. <!-- 依赖包输出目录,将来不打进jar包里 -->
  195. <outputDirectory>${project.build.directory}/lib</outputDirectory>
  196. <excludeTransitive>false</excludeTransitive>
  197. <stripVersion>false</stripVersion>
  198. <includeScope>runtime</includeScope>
  199. </configuration>
  200. </execution>
  201. </executions>
  202. </plugin>
  203. <!--指定配置文件,将resources打成外部resource-->
  204. <plugin>
  205. <groupId>org.apache.maven.plugins</groupId>
  206. <artifactId>maven-jar-plugin</artifactId>
  207. <configuration>
  208. <archive>
  209. <!-- 指定配置文件目录,这样jar运行时会去找到同目录下的resources文件夹下查找 -->
  210. <manifestEntries>
  211. <Class-Path>resources/</Class-Path>
  212. </manifestEntries>
  213. </archive>
  214. <!-- 打包时忽略的文件(也就是不打进jar包里的文件) -->
  215. <excludes>
  216. <exclude>**/*.yml</exclude>
  217. <exclude>**/*.xml</exclude>
  218. </excludes>
  219. </configuration>
  220. </plugin>
  221. <!-- 拷贝资源文件 外面的resource目录-->
  222. <plugin>
  223. <artifactId>maven-resources-plugin</artifactId>
  224. <executions>
  225. <execution>
  226. <id>copy-dependencies</id>
  227. <phase>package</phase>
  228. <goals>
  229. <goal>copy-resources</goal>
  230. </goals>
  231. <configuration>
  232. <!-- 资源文件输出目录 -->
  233. <outputDirectory>${project.build.directory}/resources</outputDirectory>
  234. <resources>
  235. <resource>
  236. <directory>src/main/resources</directory>
  237. </resource>
  238. </resources>
  239. </configuration>
  240. </execution>
  241. </executions>
  242. </plugin>
  243. </plugins>
  244. </build>
  245. </project>