pom.xml 7.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  3. xmlns="http://maven.apache.org/POM/4.0.0"
  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>top.continew</groupId>
  8. <artifactId>continew-admin</artifactId>
  9. <version>${revision}</version>
  10. </parent>
  11. <artifactId>continew-webapi</artifactId>
  12. <description>API 及打包部署模块</description>
  13. <properties>
  14. <!-- ### 打包配置相关 ### -->
  15. <!-- 启动类 -->
  16. <main-class>top.continew.admin.ContiNewAdminApplication</main-class>
  17. <!-- 程序 jar 输出目录 -->
  18. <bin-path>bin/</bin-path>
  19. <!-- 配置文件输出目录 -->
  20. <config-path>config/</config-path>
  21. <!-- 依赖 jar 输出目录 -->
  22. <lib-path>lib/</lib-path>
  23. </properties>
  24. <dependencies>
  25. <!-- ContiNew Starter 日志模块 - 拦截器版(Spring Boot Actuator HttpTrace 增强版) -->
  26. <dependency>
  27. <groupId>top.continew</groupId>
  28. <artifactId>continew-starter-log-interceptor</artifactId>
  29. </dependency>
  30. <!-- 系统管理模块(存放系统管理模块相关功能,例如:部门管理、角色管理、用户管理等) -->
  31. <dependency>
  32. <groupId>top.continew</groupId>
  33. <artifactId>continew-module-system</artifactId>
  34. </dependency>
  35. <!-- 任务调度插件(后续会改造为独立插件) -->
  36. <dependency>
  37. <groupId>top.continew</groupId>
  38. <artifactId>continew-plugin-schedule</artifactId>
  39. </dependency>
  40. <!-- 能力开放插件(后续会改造为独立插件) -->
  41. <dependency>
  42. <groupId>top.continew</groupId>
  43. <artifactId>continew-plugin-open</artifactId>
  44. </dependency>
  45. <!-- 代码生成器插件(后续会改造为独立插件) -->
  46. <dependency>
  47. <groupId>top.continew</groupId>
  48. <artifactId>continew-plugin-generator</artifactId>
  49. </dependency>
  50. <!-- Liquibase(用于管理数据库版本,跟踪、管理和应用数据库变化) -->
  51. <dependency>
  52. <groupId>org.liquibase</groupId>
  53. <artifactId>liquibase-core</artifactId>
  54. </dependency>
  55. <dependency>
  56. <groupId>org.springframework.boot</groupId>
  57. <artifactId>spring-boot-starter-test</artifactId>
  58. <scope>test</scope>
  59. </dependency>
  60. </dependencies>
  61. <build>
  62. <finalName>tg-game-admin</finalName>
  63. <plugins>
  64. <!-- Spring Boot 打包插件(将 Spring Boot Maven 应用打包为可执行的 jar 包) -->
  65. <plugin>
  66. <groupId>org.springframework.boot</groupId>
  67. <artifactId>spring-boot-maven-plugin</artifactId>
  68. <configuration>
  69. <includeSystemScope>true</includeSystemScope>
  70. </configuration>
  71. <executions>
  72. <execution>
  73. <goals>
  74. <goal>repackage</goal>
  75. </goals>
  76. </execution>
  77. </executions>
  78. </plugin>
  79. </plugins>
  80. </build>
  81. <!--<build>
  82. &lt;!&ndash; 设置构建的 jar 包名 &ndash;&gt;
  83. <finalName>${project.parent.name}</finalName>
  84. <plugins>
  85. &lt;!&ndash; Maven 打包插件 &ndash;&gt;
  86. <plugin>
  87. <groupId>org.apache.maven.plugins</groupId>
  88. <artifactId>maven-jar-plugin</artifactId>
  89. <configuration>
  90. &lt;!&ndash; 排除配置文件 &ndash;&gt;
  91. <excludes>
  92. <exclude>${config-path}</exclude>
  93. <exclude>db/</exclude>
  94. <exclude>templates/</exclude>
  95. <exclude>logback-spring.xml</exclude>
  96. </excludes>
  97. <archive>
  98. <manifest>
  99. <mainClass>${main-class}</mainClass>
  100. &lt;!&ndash; 为 MANIFEST.MF 中的 Class-Path 加入依赖 jar 目录前缀 &ndash;&gt;
  101. <classpathPrefix>../${lib-path}</classpathPrefix>
  102. <addClasspath>true</addClasspath>
  103. &lt;!&ndash; jar 包不包含唯一版本标识 &ndash;&gt;
  104. <useUniqueVersions>false</useUniqueVersions>
  105. </manifest>
  106. <manifestEntries>
  107. &lt;!&ndash;为 MANIFEST.MF 中的 Class-Path 加入配置文件目录前缀 &ndash;&gt;
  108. <Class-Path>../${config-path}</Class-Path>
  109. </manifestEntries>
  110. </archive>
  111. <outputDirectory>${project.build.directory}/app/${bin-path}</outputDirectory>
  112. </configuration>
  113. </plugin>
  114. &lt;!&ndash; 拷贝依赖 jar &ndash;&gt;
  115. <plugin>
  116. <groupId>org.apache.maven.plugins</groupId>
  117. <artifactId>maven-dependency-plugin</artifactId>
  118. <executions>
  119. <execution>
  120. <id>copy-dependencies</id>
  121. <phase>package</phase>
  122. <goals>
  123. <goal>copy-dependencies</goal>
  124. </goals>
  125. <configuration>
  126. <outputDirectory>${project.build.directory}/app/${lib-path}</outputDirectory>
  127. </configuration>
  128. </execution>
  129. </executions>
  130. </plugin>
  131. &lt;!&ndash; 拷贝配置文件 &ndash;&gt;
  132. <plugin>
  133. <groupId>org.apache.maven.plugins</groupId>
  134. <artifactId>maven-resources-plugin</artifactId>
  135. <executions>
  136. <execution>
  137. <id>copy-resources</id>
  138. <phase>package</phase>
  139. <goals>
  140. <goal>copy-resources</goal>
  141. </goals>
  142. <configuration>
  143. <resources>
  144. <resource>
  145. <directory>src/main/resources/${config-path}</directory>
  146. </resource>
  147. <resource>
  148. <directory>src/main/resources</directory>
  149. <includes>
  150. <include>db/</include>
  151. <include>templates/</include>
  152. <include>logback-spring.xml</include>
  153. </includes>
  154. </resource>
  155. </resources>
  156. <outputDirectory>${project.build.directory}/app/${config-path}</outputDirectory>
  157. </configuration>
  158. </execution>
  159. </executions>
  160. </plugin>
  161. </plugins>
  162. </build>-->
  163. </project>