pom.xml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  3. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  4. <modelVersion>4.0.0</modelVersion>
  5. <groupId>org.sky</groupId>
  6. <artifactId>Kd-Cloud</artifactId>
  7. <version>${revision}</version>
  8. <packaging>pom</packaging>
  9. <properties>
  10. <revision>2.0.1.RELEASE</revision>
  11. <java.version>17</java.version>
  12. <maven.plugin.version>3.11.0</maven.plugin.version>
  13. <maven.flatten.version>1.3.0</maven.flatten.version>
  14. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  15. <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  16. <!-- Docker仓库服务配置 -->
  17. <docker.registry.url>192.168.0.188</docker.registry.url>
  18. <docker.username>admin</docker.username>
  19. <docker.password>admin12345</docker.password>
  20. <docker.namespace>kd</docker.namespace>
  21. <docker.fabric.skip>false</docker.fabric.skip>
  22. <docker.fabric.version>0.42.0</docker.fabric.version>
  23. </properties>
  24. <modules>
  25. <module>kd-common</module>
  26. <module>kd-auth</module>
  27. <module>kd-gateway</module>
  28. <module>kd-ops</module>
  29. <module>kd-ops-api</module>
  30. <module>kd-service</module>
  31. <module>kd-service-api</module>
  32. </modules>
  33. <dependencyManagement>
  34. <dependencies>
  35. <dependency>
  36. <groupId>org.sky.platform</groupId>
  37. <artifactId>kd-bom</artifactId>
  38. <version>${revision}</version>
  39. <type>pom</type>
  40. <scope>import</scope>
  41. </dependency>
  42. <dependency>
  43. <groupId>org.sky</groupId>
  44. <artifactId>kd-common</artifactId>
  45. <version>${revision}</version>
  46. </dependency>
  47. <dependency>
  48. <groupId>org.sky</groupId>
  49. <artifactId>kd-scientific</artifactId>
  50. <version>${revision}</version>
  51. </dependency>
  52. <dependency>
  53. <groupId>org.sky</groupId>
  54. <artifactId>kd-dict-api</artifactId>
  55. <version>${revision}</version>
  56. </dependency>
  57. <dependency>
  58. <groupId>org.sky</groupId>
  59. <artifactId>kd-scope-api</artifactId>
  60. <version>${revision}</version>
  61. </dependency>
  62. <dependency>
  63. <groupId>org.sky</groupId>
  64. <artifactId>kd-desk-api</artifactId>
  65. <version>${revision}</version>
  66. </dependency>
  67. <dependency>
  68. <groupId>org.sky</groupId>
  69. <artifactId>kd-resource-api</artifactId>
  70. <version>${revision}</version>
  71. </dependency>
  72. <dependency>
  73. <groupId>org.sky</groupId>
  74. <artifactId>kd-user-api</artifactId>
  75. <version>${revision}</version>
  76. </dependency>
  77. <dependency>
  78. <groupId>org.sky</groupId>
  79. <artifactId>kd-flow-api</artifactId>
  80. <version>${revision}</version>
  81. </dependency>
  82. <dependency>
  83. <groupId>org.sky</groupId>
  84. <artifactId>kd-system-api</artifactId>
  85. <version>${revision}</version>
  86. </dependency>
  87. <dependency>
  88. <groupId>org.sky</groupId>
  89. <artifactId>kd-scientific-api</artifactId>
  90. <version>${revision}</version>
  91. </dependency>
  92. </dependencies>
  93. </dependencyManagement>
  94. <dependencies>
  95. <!--lombok-->
  96. <dependency>
  97. <groupId>org.projectlombok</groupId>
  98. <artifactId>lombok</artifactId>
  99. <scope>provided</scope>
  100. </dependency>
  101. </dependencies>
  102. <build>
  103. <finalName>${project.name}</finalName>
  104. <resources>
  105. <resource>
  106. <directory>src/main/resources</directory>
  107. </resource>
  108. <resource>
  109. <directory>src/main/java</directory>
  110. <includes>
  111. <include>**/*.xml</include>
  112. </includes>
  113. </resource>
  114. </resources>
  115. <pluginManagement>
  116. <plugins>
  117. <plugin>
  118. <groupId>org.springframework.boot</groupId>
  119. <artifactId>spring-boot-maven-plugin</artifactId>
  120. <version>3.2.10</version>
  121. <configuration>
  122. <finalName>${project.build.finalName}</finalName>
  123. <excludes>
  124. <!-- 打包的 jar 中排除 lombok -->
  125. <exclude>
  126. <groupId>org.projectlombok</groupId>
  127. <artifactId>lombok</artifactId>
  128. </exclude>
  129. </excludes>
  130. </configuration>
  131. <executions>
  132. <execution>
  133. <goals>
  134. <goal>repackage</goal>
  135. </goals>
  136. </execution>
  137. </executions>
  138. </plugin>
  139. <plugin>
  140. <groupId>io.fabric8</groupId>
  141. <artifactId>docker-maven-plugin</artifactId>
  142. <version>${docker.fabric.version}</version>
  143. <configuration>
  144. <skip>true</skip>
  145. <authConfig>
  146. <username>${docker.username}</username>
  147. <password>${docker.password}</password>
  148. </authConfig>
  149. <registry>${docker.registry.url}</registry>
  150. <images>
  151. <image>
  152. <name>${docker.namespace}/${project.build.finalName}:${project.version}</name>
  153. <alias>${project.name}</alias>
  154. <build>
  155. <dockerFile>${project.basedir}/Dockerfile</dockerFile>
  156. </build>
  157. </image>
  158. </images>
  159. <buildArgs>
  160. <JAR_FILE>${basedir}/target/${project.build.finalName}.jar</JAR_FILE>
  161. </buildArgs>
  162. </configuration>
  163. </plugin>
  164. <plugin>
  165. <groupId>org.apache.maven.plugins</groupId>
  166. <artifactId>maven-antrun-plugin</artifactId>
  167. <version>3.1.0</version>
  168. <executions>
  169. <execution>
  170. <phase>package</phase>
  171. <goals>
  172. <goal>run</goal>
  173. </goals>
  174. <configuration>
  175. <target>
  176. <!--suppress UnresolvedMavenProperty -->
  177. <copy overwrite="true"
  178. todir="${project.root.directory}/target"
  179. file="${project.build.directory}/${project.artifactId}.jar"/>
  180. </target>
  181. </configuration>
  182. </execution>
  183. </executions>
  184. </plugin>
  185. </plugins>
  186. </pluginManagement>
  187. <plugins>
  188. <plugin>
  189. <groupId>org.springframework.boot</groupId>
  190. <artifactId>spring-boot-maven-plugin</artifactId>
  191. </plugin>
  192. <plugin>
  193. <artifactId>maven-compiler-plugin</artifactId>
  194. <version>${maven.plugin.version}</version>
  195. <configuration>
  196. <source>${java.version}</source>
  197. <target>${java.version}</target>
  198. <encoding>UTF-8</encoding>
  199. <compilerArgs>
  200. <arg>-parameters</arg>
  201. </compilerArgs>
  202. </configuration>
  203. </plugin>
  204. <plugin>
  205. <groupId>org.codehaus.mojo</groupId>
  206. <artifactId>flatten-maven-plugin</artifactId>
  207. <version>${maven.flatten.version}</version>
  208. <configuration>
  209. <updatePomFile>true</updatePomFile>
  210. <flattenMode>oss</flattenMode>
  211. <pomElements>
  212. <url>remove</url>
  213. <scm>remove</scm>
  214. <developers>remove</developers>
  215. <properties>remove</properties>
  216. <repositories>remove</repositories>
  217. <distributionManagement>remove</distributionManagement>
  218. </pomElements>
  219. </configuration>
  220. <executions>
  221. <execution>
  222. <id>flatten</id>
  223. <phase>process-resources</phase>
  224. <goals>
  225. <goal>flatten</goal>
  226. </goals>
  227. </execution>
  228. <execution>
  229. <id>flatten.clean</id>
  230. <phase>clean</phase>
  231. <goals>
  232. <goal>clean</goal>
  233. </goals>
  234. </execution>
  235. </executions>
  236. </plugin>
  237. <plugin>
  238. <groupId>org.commonjava.maven.plugins</groupId>
  239. <artifactId>directory-maven-plugin</artifactId>
  240. <version>1.0</version>
  241. <executions>
  242. <execution>
  243. <id>directories</id>
  244. <goals>
  245. <goal>highest-basedir</goal>
  246. </goals>
  247. <phase>initialize</phase>
  248. <configuration>
  249. <property>project.root.directory</property>
  250. </configuration>
  251. </execution>
  252. </executions>
  253. </plugin>
  254. <plugin>
  255. <groupId>org.apache.maven.plugins</groupId>
  256. <artifactId>maven-compiler-plugin</artifactId>
  257. <configuration>
  258. <source>16</source>
  259. <target>16</target>
  260. </configuration>
  261. </plugin>
  262. </plugins>
  263. </build>
  264. <repositories>
  265. <repository>
  266. <id>aliyun-repos</id>
  267. <name>Aliyun Public Repository</name>
  268. <url>https://maven.aliyun.com/repository/public</url>
  269. <snapshots>
  270. <enabled>false</enabled>
  271. </snapshots>
  272. </repository>
  273. <repository>
  274. <id>2539567-release-mLPVzn</id>
  275. <name>Kd Release Repository</name>
  276. <url>https://packages.aliyun.com/682a8930a06d934b0140756f/maven/2539567-release-mlpvzn</url>
  277. </repository>
  278. </repositories>
  279. <pluginRepositories>
  280. <pluginRepository>
  281. <id>aliyun-plugin</id>
  282. <name>Aliyun Public Plugin</name>
  283. <url>https://maven.aliyun.com/repository/public</url>
  284. <snapshots>
  285. <enabled>false</enabled>
  286. </snapshots>
  287. </pluginRepository>
  288. </pluginRepositories>
  289. <distributionManagement>
  290. <repository>
  291. <id>2539567-release-mLPVzn</id>
  292. <name>Kd Release Repository</name>
  293. <url>https://packages.aliyun.com/682a8930a06d934b0140756f/maven/2539567-release-mlpvzn</url>
  294. </repository>
  295. <snapshotRepository>
  296. <id>2539567-release-mLPVzn</id>
  297. <name>Kd Release Repository</name>
  298. <url>https://packages.aliyun.com/682a8930a06d934b0140756f/maven/2539567-release-mlpvzn</url>
  299. </snapshotRepository>
  300. </distributionManagement>
  301. </project>