pom.xml 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179
  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.welampiot</groupId>
  7. <artifactId>CIS</artifactId>
  8. <version>1.0-SNAPSHOT</version>
  9. <properties>
  10. <maven.compiler.source>8</maven.compiler.source>
  11. <maven.compiler.target>8</maven.compiler.target>
  12. <log4j2.version>2.13.3</log4j2.version>
  13. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  14. </properties>
  15. <!-- 导入springboot版本和框架依赖 -->
  16. <parent>
  17. <groupId>org.springframework.boot</groupId>
  18. <artifactId>spring-boot-starter-parent</artifactId>
  19. <version>2.5.1</version>
  20. <relativePath></relativePath>
  21. </parent>
  22. <dependencies>
  23. <dependency>
  24. <groupId>org.springframework.boot</groupId>
  25. <artifactId>spring-boot-starter-web</artifactId>
  26. </dependency>
  27. <dependency>
  28. <groupId>mysql</groupId>
  29. <artifactId>mysql-connector-java</artifactId>
  30. </dependency>
  31. <dependency>
  32. <groupId>org.mybatis.spring.boot</groupId>
  33. <artifactId>mybatis-spring-boot-starter</artifactId>
  34. <version>2.2.2</version>
  35. </dependency>
  36. <dependency>
  37. <groupId>com.alibaba</groupId>
  38. <artifactId>druid</artifactId>
  39. <version>1.2.3</version>
  40. </dependency>
  41. <dependency>
  42. <groupId>com.alibaba</groupId>
  43. <artifactId>druid-spring-boot-starter</artifactId>
  44. <version>1.1.20</version>
  45. </dependency>
  46. <dependency>
  47. <groupId>org.apache.commons</groupId>
  48. <artifactId>commons-lang3</artifactId>
  49. <version>3.9</version>
  50. </dependency>
  51. <dependency>
  52. <groupId>org.projectlombok</groupId>
  53. <artifactId>lombok</artifactId>
  54. </dependency>
  55. <dependency>
  56. <groupId>junit</groupId>
  57. <artifactId>junit</artifactId>
  58. <scope>test</scope>
  59. </dependency>
  60. <dependency>
  61. <groupId>org.springframework.boot</groupId>
  62. <artifactId>spring-boot-starter-test</artifactId>
  63. <scope>test</scope>
  64. <exclusions>
  65. <exclusion>
  66. <groupId>org.junit.vintage</groupId>
  67. <artifactId>junit-vintage-engine</artifactId>
  68. </exclusion>
  69. </exclusions>
  70. </dependency>
  71. <dependency>
  72. <groupId>org.springframework.boot</groupId>
  73. <artifactId>spring-boot-starter-security</artifactId>
  74. </dependency>
  75. <dependency>
  76. <groupId>org.springframework.security</groupId>
  77. <artifactId>spring-security-config</artifactId>
  78. </dependency>
  79. <dependency>
  80. <groupId>org.springframework.boot</groupId>
  81. <artifactId>spring-boot-starter-validation</artifactId>
  82. </dependency>
  83. <dependency>
  84. <groupId>commons-codec</groupId>
  85. <artifactId>commons-codec</artifactId>
  86. <version>1.14</version>
  87. </dependency>
  88. <dependency>
  89. <groupId>be.c4j.ee.security.octopus</groupId>
  90. <artifactId>authentication</artifactId>
  91. <version>0.9.7.2</version>
  92. <type>pom</type>
  93. </dependency>
  94. <dependency>
  95. <groupId>com.alibaba</groupId>
  96. <artifactId>fastjson</artifactId>
  97. <version>1.2.33</version>
  98. </dependency>
  99. </dependencies>
  100. <!-- maven多环境打包配置 -->
  101. <profiles>
  102. <!-- 开发环境 -->
  103. <profile>
  104. <id>dev</id>
  105. <properties>
  106. <spring.profiles.active>dev</spring.profiles.active>
  107. </properties>
  108. <!-- 设置为默认环境 -->
  109. <activation>
  110. <activeByDefault>true</activeByDefault>
  111. </activation>
  112. </profile>
  113. <!-- 生产环境 -->
  114. <profile>
  115. <id>prod</id>
  116. <properties>
  117. <spring.profiles.active>prod</spring.profiles.active>
  118. </properties>
  119. </profile>
  120. </profiles>
  121. <!--添加maven插件,项目的打包工具,打成jar包,否则在打包运行时报错 -->
  122. <build>
  123. <!-- 打包名格式:项目名-环境-打包时间.jar -->
  124. <finalName>${project.artifactId}-${spring.profiles.active}</finalName>
  125. <resources>
  126. <resource>
  127. <directory>src/main/java</directory>
  128. <includes>
  129. <include>**/*.xml</include>
  130. <include>**/*.yml</include>
  131. <include>**/*.properties</include>
  132. </includes>
  133. </resource>
  134. <resource>
  135. <directory>src/main/resources</directory>
  136. <includes>
  137. <include>**/*.xml</include>
  138. <include>**/*.yml</include>
  139. <include>**/*.properties</include>
  140. </includes>
  141. <filtering>true</filtering>
  142. </resource>
  143. </resources>
  144. <plugins>
  145. <plugin>
  146. <groupId>org.springframework.boot</groupId>
  147. <artifactId>spring-boot-maven-plugin</artifactId>
  148. <version>2.2.2.RELEASE</version>
  149. <configuration>
  150. <mainClass>com.welampiot.ServerApplication</mainClass>
  151. <layout>JAR</layout>
  152. </configuration>
  153. <executions>
  154. <execution>
  155. <goals>
  156. <goal>repackage</goal>
  157. </goals>
  158. <configuration>
  159. <attach>false</attach>
  160. </configuration>
  161. </execution>
  162. </executions>
  163. </plugin>
  164. <!-- maven 打包时跳过测试 -->
  165. <plugin>
  166. <groupId>org.apache.maven.plugins</groupId>
  167. <artifactId>maven-surefire-plugin</artifactId>
  168. <configuration>
  169. <skipTests>true</skipTests>
  170. </configuration>
  171. </plugin>
  172. </plugins>
  173. </build>
  174. </project>