pom.xml 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236
  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. <parent>
  6. <groupId>com.yihu.jw</groupId>
  7. <artifactId>wlyy-parent-pom</artifactId>
  8. <version>2.0.0</version>
  9. <relativePath>../../wlyy-parent-pom/pom.xml</relativePath>
  10. </parent>
  11. <modelVersion>4.0.0</modelVersion>
  12. <artifactId>ag-basic</artifactId>
  13. <version>${parent.version}</version>
  14. <packaging>jar</packaging>
  15. <dependencies>
  16. <!-- 支持Tomcat启动 -->
  17. <dependency>
  18. <groupId>org.springframework.boot</groupId>
  19. <artifactId>spring-boot-starter-web</artifactId>
  20. <exclusions>
  21. <exclusion>
  22. <groupId>org.springframework.boot</groupId>
  23. <artifactId>spring-boot-starter-tomcat</artifactId>
  24. </exclusion>
  25. </exclusions>
  26. </dependency>
  27. <dependency>
  28. <groupId>org.springframework.boot</groupId>
  29. <artifactId>spring-boot-starter-tomcat</artifactId>
  30. <scope>provided</scope>
  31. </dependency>
  32. <dependency>
  33. <groupId>javax.servlet</groupId>
  34. <artifactId>javax.servlet-api</artifactId>
  35. </dependency>
  36. <dependency>
  37. <groupId>org.apache.tomcat.embed</groupId>
  38. <artifactId>tomcat-embed-jasper</artifactId>
  39. </dependency>
  40. <!-- 支持Tomcat启动 -->
  41. <dependency>
  42. <groupId>org.springframework.cloud</groupId>
  43. <artifactId>spring-cloud-starter-eureka</artifactId>
  44. </dependency>
  45. <dependency>
  46. <groupId>org.springframework.cloud</groupId>
  47. <artifactId>spring-cloud-starter-zuul</artifactId>
  48. </dependency>
  49. <dependency>
  50. <groupId>org.springframework.cloud</groupId>
  51. <artifactId>spring-cloud-starter-config</artifactId>
  52. </dependency>
  53. <dependency>
  54. <groupId>org.springframework.retry</groupId>
  55. <artifactId>spring-retry</artifactId>
  56. </dependency>
  57. <dependency>
  58. <groupId>net.sf.json-lib</groupId>
  59. <artifactId>json-lib</artifactId>
  60. <version>2.4</version>
  61. <exclusions>
  62. <exclusion>
  63. <groupId>org.slf4j</groupId>
  64. <artifactId>slf4j-log4j12</artifactId>
  65. </exclusion>
  66. </exclusions>
  67. </dependency>
  68. <!--<dependency>
  69. <groupId>org.springframework.cloud</groupId>
  70. <artifactId>spring-cloud-starter-zipkin</artifactId>
  71. </dependency>-->
  72. <!-- 安全认证中心-->
  73. <dependency>
  74. <groupId>org.springframework.boot</groupId>
  75. <artifactId>spring-boot-starter-security</artifactId>
  76. </dependency>
  77. <dependency>
  78. <groupId>org.springframework.security.oauth</groupId>
  79. <artifactId>spring-security-oauth2</artifactId>
  80. </dependency>
  81. <!-- 安全认证中心-->
  82. <!-- Redis -->
  83. <dependency>
  84. <groupId>org.springframework.boot</groupId>
  85. <artifactId>spring-boot-starter-data-redis</artifactId>
  86. </dependency>
  87. <dependency>
  88. <groupId>redis.clients</groupId>
  89. <artifactId>jedis</artifactId>
  90. </dependency>
  91. <!-- Redis -->
  92. <!-- JdbcTemplate-->
  93. <dependency>
  94. <groupId>org.springframework.boot</groupId>
  95. <artifactId>spring-boot-starter-jdbc</artifactId>
  96. </dependency>
  97. <dependency>
  98. <groupId>mysql</groupId>
  99. <artifactId>mysql-connector-java</artifactId>
  100. <scope>runtime</scope>
  101. </dependency>
  102. <dependency>
  103. <groupId>org.apache.commons</groupId>
  104. <artifactId>commons-dbcp2</artifactId>
  105. </dependency>
  106. <!-- JdbcTemplate-->
  107. <dependency>
  108. <groupId>com.yihu.jw</groupId>
  109. <artifactId>common-web</artifactId>
  110. </dependency>
  111. <dependency>
  112. <groupId>com.yihu.jw</groupId>
  113. <artifactId>common-rest-model</artifactId>
  114. </dependency>
  115. <dependency>
  116. <groupId>commons-fileupload</groupId>
  117. <artifactId>commons-fileupload</artifactId>
  118. <version>1.3.1</version>
  119. </dependency>
  120. <!--oracle驱动-->
  121. <dependency>
  122. <groupId>com.oracle</groupId>
  123. <artifactId>ojdbc6</artifactId>
  124. <version>11.2.0.3</version>
  125. </dependency>
  126. </dependencies>
  127. <!--<build>
  128. <finalName>ag-basic</finalName>
  129. <plugins>
  130. <plugin>
  131. <groupId>org.springframework.boot</groupId>
  132. <artifactId>spring-boot-maven-plugin</artifactId>
  133. </plugin>
  134. <plugin>
  135. <artifactId>maven-war-plugin</artifactId>
  136. <configuration>
  137. <failOnMissingWebXml>false</failOnMissingWebXml>
  138. <filteringDeploymentDescriptors>true</filteringDeploymentDescriptors>
  139. </configuration>
  140. </plugin>
  141. </plugins>
  142. </build>
  143. -->
  144. <build>
  145. <finalName>ag-basic</finalName>
  146. <plugins>
  147. <plugin>
  148. <groupId>org.apache.maven.plugins</groupId>
  149. <artifactId>maven-jar-plugin</artifactId>
  150. <configuration>
  151. <archive>
  152. <!-- 生成的jar中,不要包含pom.xml和pom.properties这两个文件 -->
  153. <addMavenDescriptor>false</addMavenDescriptor>
  154. <manifest>
  155. <!-- 是否要把第三方jar加入到类构建路径 -->
  156. <addClasspath>true</addClasspath>
  157. <!-- 外部依赖jar包的最终位置 -->
  158. <classpathPrefix>lib/</classpathPrefix>
  159. <mainClass>com.yihu.AgBasicServer</mainClass>
  160. </manifest>
  161. </archive>
  162. </configuration>
  163. </plugin>
  164. <!--拷贝依赖到jar外面的lib目录-->
  165. <plugin>
  166. <groupId>org.apache.maven.plugins</groupId>
  167. <artifactId>maven-dependency-plugin</artifactId>
  168. <executions>
  169. <execution>
  170. <id>copy-lib</id>
  171. <phase>package</phase>
  172. <goals>
  173. <goal>copy-dependencies</goal>
  174. </goals>
  175. <configuration>
  176. <!-- 依赖包输出目录,将来不打进jar包里 -->
  177. <outputDirectory>${project.build.directory}/lib</outputDirectory>
  178. <excludeTransitive>false</excludeTransitive>
  179. <stripVersion>false</stripVersion>
  180. <includeScope>runtime</includeScope>
  181. </configuration>
  182. </execution>
  183. </executions>
  184. </plugin>
  185. <!--指定配置文件,将resources打成外部resource-->
  186. <plugin>
  187. <groupId>org.apache.maven.plugins</groupId>
  188. <artifactId>maven-jar-plugin</artifactId>
  189. <configuration>
  190. <archive>
  191. <!-- 指定配置文件目录,这样jar运行时会去找到同目录下的resources文件夹下查找 -->
  192. <manifestEntries>
  193. <Class-Path>resources/</Class-Path>
  194. </manifestEntries>
  195. </archive>
  196. <!-- 打包时忽略的文件(也就是不打进jar包里的文件) -->
  197. <excludes>
  198. <exclude>**/*.yml</exclude>
  199. <exclude>**/*.xml</exclude>
  200. </excludes>
  201. </configuration>
  202. </plugin>
  203. <!-- 拷贝资源文件 外面的resource目录-->
  204. <plugin>
  205. <artifactId>maven-resources-plugin</artifactId>
  206. <executions>
  207. <execution>
  208. <id>copy-dependencies</id>
  209. <phase>package</phase>
  210. <goals>
  211. <goal>copy-resources</goal>
  212. </goals>
  213. <configuration>
  214. <!-- 资源文件输出目录 -->
  215. <outputDirectory>${project.build.directory}/resources</outputDirectory>
  216. <resources>
  217. <resource>
  218. <directory>src/main/resources</directory>
  219. </resource>
  220. </resources>
  221. </configuration>
  222. </execution>
  223. </executions>
  224. </plugin>
  225. </plugins>
  226. </build>
  227. </project>