pom.xml 6.5 KB

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