pom.xml 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166
  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.diagbot</groupId>
  7. <artifactId>diagbotcloud</artifactId>
  8. <version>0.0.1-SNAPSHOT</version>
  9. </parent>
  10. <modelVersion>4.0.0</modelVersion>
  11. <artifactId>gateway-service</artifactId>
  12. <packaging>jar</packaging>
  13. <name>gateway-service</name>
  14. <description>Gateway service project for Spring Boot</description>
  15. <dependencies>
  16. <dependency>
  17. <groupId>org.springframework.boot</groupId>
  18. <artifactId>spring-boot-starter-actuator</artifactId>
  19. </dependency>
  20. <dependency>
  21. <groupId>org.springframework.cloud</groupId>
  22. <artifactId>spring-cloud-starter-gateway</artifactId>
  23. </dependency>
  24. <dependency>
  25. <groupId>org.springframework.boot</groupId>
  26. <artifactId>spring-boot-starter-data-redis-reactive</artifactId>
  27. </dependency>
  28. <!-- 配置-->
  29. <dependency>
  30. <groupId>org.springframework.cloud</groupId>
  31. <artifactId>spring-cloud-starter-config</artifactId>
  32. </dependency>
  33. <!--<dependency>-->
  34. <!--<groupId>org.springframework.cloud</groupId>-->
  35. <!--<artifactId>spring-cloud-starter</artifactId>-->
  36. <!--</dependency>-->
  37. <dependency>
  38. <groupId>org.springframework.cloud</groupId>
  39. <artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
  40. </dependency>
  41. <dependency>
  42. <groupId>org.projectlombok</groupId>
  43. <artifactId>lombok</artifactId>
  44. <optional>true</optional>
  45. </dependency>
  46. <!--swagger-->
  47. <dependency>
  48. <groupId>io.springfox</groupId>
  49. <artifactId>springfox-swagger2</artifactId>
  50. </dependency>
  51. <dependency>
  52. <groupId>io.springfox</groupId>
  53. <artifactId>springfox-swagger-ui</artifactId>
  54. </dependency>
  55. <!--knife4j-->
  56. <dependency>
  57. <groupId>com.github.xiaoymin</groupId>
  58. <artifactId>knife4j-spring-ui</artifactId>
  59. </dependency>
  60. <!-- 开启feign-->
  61. <!--<dependency>-->
  62. <!--<groupId>org.springframework.cloud</groupId>-->
  63. <!--<artifactId>spring-cloud-starter-openfeign</artifactId>-->
  64. <!--</dependency>-->
  65. <dependency>
  66. <groupId>org.springframework.cloud</groupId>
  67. <artifactId>spring-cloud-loadbalancer</artifactId>
  68. </dependency>
  69. <dependency>
  70. <groupId>org.springframework.cloud</groupId>
  71. <artifactId>spring-cloud-starter-netflix-hystrix</artifactId>
  72. </dependency>
  73. <!-- 必须加上,jedis依赖此 -->
  74. <dependency>
  75. <groupId>org.apache.commons</groupId>
  76. <artifactId>commons-pool2</artifactId>
  77. </dependency>
  78. <dependency>
  79. <groupId>com.diagbot</groupId>
  80. <artifactId>common</artifactId>
  81. <version>0.0.1-SNAPSHOT</version>
  82. </dependency>
  83. </dependencies>
  84. <dependencyManagement>
  85. <dependencies>
  86. <dependency>
  87. <groupId>org.springframework.cloud</groupId>
  88. <artifactId>spring-cloud-dependencies</artifactId>
  89. <version>${spring-cloud.version}</version>
  90. <type>pom</type>
  91. <scope>import</scope>
  92. </dependency>
  93. </dependencies>
  94. </dependencyManagement>
  95. <build>
  96. <plugins>
  97. <plugin>
  98. <artifactId>maven-dependency-plugin</artifactId>
  99. <executions>
  100. <execution>
  101. <id>copy</id>
  102. <phase>package</phase>
  103. <goals>
  104. <goal>copy-dependencies</goal>
  105. </goals>
  106. <configuration>
  107. <outputDirectory>${project.build.directory}/lib</outputDirectory>
  108. </configuration>
  109. </execution>
  110. </executions>
  111. </plugin>
  112. <plugin>
  113. <artifactId>maven-resources-plugin</artifactId>
  114. <executions>
  115. <execution>
  116. <id>copy-resources</id>
  117. <phase>package</phase>
  118. <goals>
  119. <goal>copy-resources</goal>
  120. </goals>
  121. <configuration>
  122. <resources>
  123. <resource>
  124. <directory>src/main/resources</directory>
  125. </resource>
  126. </resources>
  127. <outputDirectory>${project.build.directory}/resources</outputDirectory>
  128. </configuration>
  129. </execution>
  130. </executions>
  131. </plugin>
  132. <plugin>
  133. <artifactId>maven-jar-plugin</artifactId>
  134. <configuration>
  135. <excludes>
  136. <exclude>mapper</exclude>
  137. <exclude>*.**</exclude>
  138. <exclude>**/*.xml</exclude>
  139. <exclude>**/*.yml</exclude>
  140. </excludes>
  141. <archive>
  142. <manifest>
  143. <mainClass>${main-class}</mainClass>
  144. <addClasspath>true</addClasspath>
  145. <classpathPrefix>lib/</classpathPrefix>
  146. <useUniqueVersions>false</useUniqueVersions>
  147. </manifest>
  148. </archive>
  149. <outputDirectory>${project.build.directory}</outputDirectory>
  150. </configuration>
  151. </plugin>
  152. </plugins>
  153. </build>
  154. </project>