pom.xml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277
  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. <groupId>com.macro.mall</groupId>
  7. <artifactId>mall</artifactId>
  8. <version>1.0-SNAPSHOT</version>
  9. <packaging>pom</packaging>
  10. <modules>
  11. <module>mall-common</module>
  12. <module>mall-mbg</module>
  13. <module>mall-security</module>
  14. <module>mall-demo</module>
  15. <module>mall-admin</module>
  16. <module>mall-search</module>
  17. <module>mall-portal</module>
  18. </modules>
  19. <parent>
  20. <groupId>org.springframework.boot</groupId>
  21. <artifactId>spring-boot-starter-parent</artifactId>
  22. <version>2.7.5</version>
  23. <relativePath/> <!-- lookup parent from repository -->
  24. </parent>
  25. <properties>
  26. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  27. <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  28. <java.version>1.8</java.version>
  29. <skipTests>true</skipTests>
  30. <docker.host>http://192.168.1.74:2375</docker.host>
  31. <docker.maven.plugin.version>0.40.2</docker.maven.plugin.version>
  32. <pagehelper-starter.version>1.4.5</pagehelper-starter.version>
  33. <pagehelper.version>5.3.2</pagehelper.version>
  34. <druid.version>1.2.14</druid.version>
  35. <hutool.version>5.8.9</hutool.version>
  36. <springfox-swagger.version>3.0.0</springfox-swagger.version>
  37. <swagger-models.version>1.6.0</swagger-models.version>
  38. <swagger-annotations.version>1.6.0</swagger-annotations.version>
  39. <mybatis-generator.version>1.4.1</mybatis-generator.version>
  40. <mybatis.version>3.5.10</mybatis.version>
  41. <mysql-connector.version>8.0.29</mysql-connector.version>
  42. <spring-data-commons.version>2.7.5</spring-data-commons.version>
  43. <jjwt.version>0.9.1</jjwt.version>
  44. <aliyun-oss.version>2.5.0</aliyun-oss.version>
  45. <alipay-sdk.version>4.38.61.ALL</alipay-sdk.version>
  46. <logstash-logback.version>7.2</logstash-logback.version>
  47. <minio.version>8.4.5</minio.version>
  48. <jaxb-api.version>2.3.1</jaxb-api.version>
  49. <mall-common.version>1.0-SNAPSHOT</mall-common.version>
  50. <mall-mbg.version>1.0-SNAPSHOT</mall-mbg.version>
  51. <mall-security.version>1.0-SNAPSHOT</mall-security.version>
  52. </properties>
  53. <dependencies>
  54. <dependency>
  55. <groupId>org.springframework.boot</groupId>
  56. <artifactId>spring-boot-starter-actuator</artifactId>
  57. </dependency>
  58. <dependency>
  59. <groupId>org.springframework.boot</groupId>
  60. <artifactId>spring-boot-starter-aop</artifactId>
  61. </dependency>
  62. <dependency>
  63. <groupId>org.springframework.boot</groupId>
  64. <artifactId>spring-boot-starter-test</artifactId>
  65. <scope>test</scope>
  66. </dependency>
  67. <dependency>
  68. <groupId>cn.hutool</groupId>
  69. <artifactId>hutool-all</artifactId>
  70. </dependency>
  71. <dependency>
  72. <groupId>org.projectlombok</groupId>
  73. <artifactId>lombok</artifactId>
  74. <version>1.18.30</version>
  75. <scope>provided</scope>
  76. </dependency>
  77. <dependency>
  78. <groupId>org.springframework.boot</groupId>
  79. <artifactId>spring-boot-configuration-processor</artifactId>
  80. <optional>true</optional>
  81. </dependency>
  82. <!--解决JDK 11 兼容性问题-->
  83. <dependency>
  84. <groupId>javax.xml.bind</groupId>
  85. <artifactId>jaxb-api</artifactId>
  86. <version>${jaxb-api.version}</version>
  87. </dependency>
  88. </dependencies>
  89. <dependencyManagement>
  90. <dependencies>
  91. <!--mall通用模块-->
  92. <dependency>
  93. <groupId>com.macro.mall</groupId>
  94. <artifactId>mall-common</artifactId>
  95. <version>${mall-common.version}</version>
  96. </dependency>
  97. <!--mall中MBG生成模块-->
  98. <dependency>
  99. <groupId>com.macro.mall</groupId>
  100. <artifactId>mall-mbg</artifactId>
  101. <version>${mall-mbg.version}</version>
  102. </dependency>
  103. <!--mall安全模块-->
  104. <dependency>
  105. <groupId>com.macro.mall</groupId>
  106. <artifactId>mall-security</artifactId>
  107. <version>${mall-security.version}</version>
  108. </dependency>
  109. <!--MyBatis分页插件starter-->
  110. <dependency>
  111. <groupId>com.github.pagehelper</groupId>
  112. <artifactId>pagehelper-spring-boot-starter</artifactId>
  113. <version>${pagehelper-starter.version}</version>
  114. </dependency>
  115. <!--MyBatis分页插件-->
  116. <dependency>
  117. <groupId>com.github.pagehelper</groupId>
  118. <artifactId>pagehelper</artifactId>
  119. <version>${pagehelper.version}</version>
  120. </dependency>
  121. <!--集成druid连接池-->
  122. <dependency>
  123. <groupId>com.alibaba</groupId>
  124. <artifactId>druid-spring-boot-starter</artifactId>
  125. <version>${druid.version}</version>
  126. </dependency>
  127. <!--Hutool Java工具包-->
  128. <dependency>
  129. <groupId>cn.hutool</groupId>
  130. <artifactId>hutool-all</artifactId>
  131. <version>${hutool.version}</version>
  132. </dependency>
  133. <!--Swagger-UI API文档生产工具-->
  134. <dependency>
  135. <groupId>io.springfox</groupId>
  136. <artifactId>springfox-boot-starter</artifactId>
  137. <version>${springfox-swagger.version}</version>
  138. </dependency>
  139. <!--解决Swagger访问主页时的NumberFormatException问题-->
  140. <dependency>
  141. <groupId>io.swagger</groupId>
  142. <artifactId>swagger-models</artifactId>
  143. <version>${swagger-models.version}</version>
  144. </dependency>
  145. <dependency>
  146. <groupId>io.swagger</groupId>
  147. <artifactId>swagger-annotations</artifactId>
  148. <version>${swagger-annotations.version}</version>
  149. </dependency>
  150. <!-- MyBatis 生成器 -->
  151. <dependency>
  152. <groupId>org.mybatis.generator</groupId>
  153. <artifactId>mybatis-generator-core</artifactId>
  154. <version>${mybatis-generator.version}</version>
  155. </dependency>
  156. <!-- MyBatis-->
  157. <dependency>
  158. <groupId>org.mybatis</groupId>
  159. <artifactId>mybatis</artifactId>
  160. <version>${mybatis.version}</version>
  161. </dependency>
  162. <!--Mysql数据库驱动-->
  163. <dependency>
  164. <groupId>mysql</groupId>
  165. <artifactId>mysql-connector-java</artifactId>
  166. <version>${mysql-connector.version}</version>
  167. </dependency>
  168. <!--SpringData工具包-->
  169. <dependency>
  170. <groupId>org.springframework.data</groupId>
  171. <artifactId>spring-data-commons</artifactId>
  172. <version>${spring-data-commons.version}</version>
  173. </dependency>
  174. <!--JWT(Json Web Token)登录支持-->
  175. <dependency>
  176. <groupId>io.jsonwebtoken</groupId>
  177. <artifactId>jjwt</artifactId>
  178. <version>${jjwt.version}</version>
  179. </dependency>
  180. <!-- 阿里云OSS -->
  181. <dependency>
  182. <groupId>com.aliyun.oss</groupId>
  183. <artifactId>aliyun-sdk-oss</artifactId>
  184. <version>${aliyun-oss.version}</version>
  185. </dependency>
  186. <!--集成logstash-->
  187. <dependency>
  188. <groupId>net.logstash.logback</groupId>
  189. <artifactId>logstash-logback-encoder</artifactId>
  190. <version>${logstash-logback.version}</version>
  191. </dependency>
  192. <!--MinIO JAVA SDK-->
  193. <dependency>
  194. <groupId>io.minio</groupId>
  195. <artifactId>minio</artifactId>
  196. <version>${minio.version}</version>
  197. </dependency>
  198. </dependencies>
  199. </dependencyManagement>
  200. <build>
  201. <pluginManagement>
  202. <plugins>
  203. <plugin>
  204. <groupId>org.springframework.boot</groupId>
  205. <artifactId>spring-boot-maven-plugin</artifactId>
  206. </plugin>
  207. <plugin>
  208. <groupId>io.fabric8</groupId>
  209. <artifactId>docker-maven-plugin</artifactId>
  210. <version>${docker.maven.plugin.version}</version>
  211. <executions>
  212. <!--如果想在项目打包时构建镜像添加-->
  213. <execution>
  214. <id>build-image</id>
  215. <phase>package</phase>
  216. <goals>
  217. <goal>build</goal>
  218. </goals>
  219. </execution>
  220. </executions>
  221. <configuration>
  222. <!-- Docker 远程管理地址-->
  223. <dockerHost>${docker.host}</dockerHost>
  224. <images>
  225. <image>
  226. <!--定义镜像名称-->
  227. <name>mall/${project.name}:${project.version}</name>
  228. <!--定义镜像构建行为-->
  229. <build>
  230. <!--定义基础镜像-->
  231. <from>openjdk:8</from>
  232. <args>
  233. <JAR_FILE>${project.build.finalName}.jar</JAR_FILE>
  234. </args>
  235. <!--定义哪些文件拷贝到容器中-->
  236. <assembly>
  237. <!--定义拷贝到容器的目录-->
  238. <targetDir>/</targetDir>
  239. <!--只拷贝生成的jar包-->
  240. <descriptorRef>artifact</descriptorRef>
  241. </assembly>
  242. <!--定义容器启动命令-->
  243. <entryPoint>["java", "-jar","-Dspring.profiles.active=dev","/${project.build.finalName}.jar"]</entryPoint>
  244. <!--定义维护者-->
  245. <maintainer>macrozheng</maintainer>
  246. </build>
  247. </image>
  248. </images>
  249. </configuration>
  250. </plugin>
  251. </plugins>
  252. </pluginManagement>
  253. </build>
  254. <!--使用aliyun的Maven镜像源提升下载速度-->
  255. <repositories>
  256. <repository>
  257. <id>aliyunmaven</id>
  258. <name>aliyun</name>
  259. <url>https://maven.aliyun.com/repository/public</url>
  260. </repository>
  261. <repository>
  262. <id>central2</id>
  263. <name>central2</name>
  264. <url>https://repo1.maven.org/maven2/</url>
  265. </repository>
  266. </repositories>
  267. </project>