Нет описания

pom.xml 9.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318
  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>io.renren</groupId>
  6. <artifactId>renren-fast</artifactId>
  7. <version>2.1.0</version>
  8. <packaging>jar</packaging>
  9. <description>renren-fast</description>
  10. <parent>
  11. <groupId>org.springframework.boot</groupId>
  12. <artifactId>spring-boot-starter-parent</artifactId>
  13. <version>2.0.0.RELEASE</version>
  14. </parent>
  15. <properties>
  16. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  17. <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  18. <java.version>1.8</java.version>
  19. <mybatisplus.spring.boot.version>1.0.5</mybatisplus.spring.boot.version>
  20. <mybatisplus.version>2.1.9</mybatisplus.version>
  21. <mysql.version>5.1.38</mysql.version>
  22. <mssql.version>4.0</mssql.version>
  23. <oracle.version>11.2.0.3</oracle.version>
  24. <druid.version>1.1.9</druid.version>
  25. <quartz.version>2.3.0</quartz.version>
  26. <commons.lang.version>2.6</commons.lang.version>
  27. <commons.fileupload.version>1.2.2</commons.fileupload.version>
  28. <commons.io.version>2.5</commons.io.version>
  29. <commons.codec.version>1.10</commons.codec.version>
  30. <commons.configuration.version>1.10</commons.configuration.version>
  31. <shiro.version>1.3.2</shiro.version>
  32. <jwt.version>0.7.0</jwt.version>
  33. <kaptcha.version>0.0.9</kaptcha.version>
  34. <qiniu.version>[7.2.0, 7.2.99]</qiniu.version>
  35. <aliyun.oss.version>2.8.3</aliyun.oss.version>
  36. <qcloud.cos.version>4.4</qcloud.cos.version>
  37. <swagger.version>2.8.0</swagger.version>
  38. <joda.time.version>2.9.9</joda.time.version>
  39. <fastjson.version>1.2.45</fastjson.version>
  40. <!--wagon plugin 配置-->
  41. <service-path>/work/renren</service-path>
  42. <pack-name>${project.artifactId}-${project.version}.jar</pack-name>
  43. <remote-addr>192.168.1.10:22</remote-addr>
  44. <remote-username>root</remote-username>
  45. <remote-passwd>123456</remote-passwd>
  46. </properties>
  47. <dependencies>
  48. <dependency>
  49. <groupId>com.alibaba</groupId>
  50. <artifactId>fastjson</artifactId>
  51. <version>${fastjson.version}</version>
  52. </dependency>
  53. <dependency>
  54. <groupId>org.springframework.boot</groupId>
  55. <artifactId>spring-boot-starter-test</artifactId>
  56. <scope>test</scope>
  57. </dependency>
  58. <dependency>
  59. <groupId>org.springframework.boot</groupId>
  60. <artifactId>spring-boot-starter-web</artifactId>
  61. </dependency>
  62. <dependency>
  63. <groupId>org.springframework.boot</groupId>
  64. <artifactId>spring-boot-starter-aop</artifactId>
  65. </dependency>
  66. <dependency>
  67. <groupId>org.springframework</groupId>
  68. <artifactId>spring-context-support</artifactId>
  69. </dependency>
  70. <dependency>
  71. <groupId>org.springframework.boot</groupId>
  72. <artifactId>spring-boot-starter-data-redis</artifactId>
  73. </dependency>
  74. <dependency>
  75. <groupId>org.springframework.boot</groupId>
  76. <artifactId>spring-boot-configuration-processor</artifactId>
  77. <optional>true</optional>
  78. </dependency>
  79. <!--<dependency>-->
  80. <!--<groupId>org.springframework.boot</groupId>-->
  81. <!--<artifactId>spring-boot-devtools</artifactId>-->
  82. <!--<optional>true</optional>-->
  83. <!--</dependency>-->
  84. <dependency>
  85. <groupId>com.baomidou</groupId>
  86. <artifactId>mybatisplus-spring-boot-starter</artifactId>
  87. <version>${mybatisplus.spring.boot.version}</version>
  88. </dependency>
  89. <dependency>
  90. <groupId>com.baomidou</groupId>
  91. <artifactId>mybatis-plus</artifactId>
  92. <version>${mybatisplus.version}</version>
  93. </dependency>
  94. <dependency>
  95. <groupId>mysql</groupId>
  96. <artifactId>mysql-connector-java</artifactId>
  97. <version>${mysql.version}</version>
  98. </dependency>
  99. <!--oracle驱动-->
  100. <dependency>
  101. <groupId>com.oracle</groupId>
  102. <artifactId>ojdbc6</artifactId>
  103. <version>${oracle.version}</version>
  104. </dependency>
  105. <!--mssql驱动-->
  106. <dependency>
  107. <groupId>com.microsoft.sqlserver</groupId>
  108. <artifactId>sqljdbc4</artifactId>
  109. <version>${mssql.version}</version>
  110. </dependency>
  111. <!--postgresql驱动-->
  112. <dependency>
  113. <groupId>org.postgresql</groupId>
  114. <artifactId>postgresql</artifactId>
  115. </dependency>
  116. <dependency>
  117. <groupId>com.alibaba</groupId>
  118. <artifactId>druid-spring-boot-starter</artifactId>
  119. <version>${druid.version}</version>
  120. </dependency>
  121. <dependency>
  122. <groupId>org.quartz-scheduler</groupId>
  123. <artifactId>quartz</artifactId>
  124. <version>${quartz.version}</version>
  125. <exclusions>
  126. <exclusion>
  127. <groupId>com.mchange</groupId>
  128. <artifactId>c3p0</artifactId>
  129. </exclusion>
  130. </exclusions>
  131. </dependency>
  132. <dependency>
  133. <groupId>commons-lang</groupId>
  134. <artifactId>commons-lang</artifactId>
  135. <version>${commons.lang.version}</version>
  136. </dependency>
  137. <dependency>
  138. <groupId>commons-fileupload</groupId>
  139. <artifactId>commons-fileupload</artifactId>
  140. <version>${commons.fileupload.version}</version>
  141. </dependency>
  142. <dependency>
  143. <groupId>commons-io</groupId>
  144. <artifactId>commons-io</artifactId>
  145. <version>${commons.io.version}</version>
  146. </dependency>
  147. <dependency>
  148. <groupId>commons-codec</groupId>
  149. <artifactId>commons-codec</artifactId>
  150. <version>${commons.codec.version}</version>
  151. </dependency>
  152. <dependency>
  153. <groupId>commons-configuration</groupId>
  154. <artifactId>commons-configuration</artifactId>
  155. <version>${commons.configuration.version}</version>
  156. </dependency>
  157. <dependency>
  158. <groupId>org.apache.shiro</groupId>
  159. <artifactId>shiro-core</artifactId>
  160. <version>${shiro.version}</version>
  161. </dependency>
  162. <dependency>
  163. <groupId>org.apache.shiro</groupId>
  164. <artifactId>shiro-spring</artifactId>
  165. <version>${shiro.version}</version>
  166. </dependency>
  167. <dependency>
  168. <groupId>io.jsonwebtoken</groupId>
  169. <artifactId>jjwt</artifactId>
  170. <version>${jwt.version}</version>
  171. </dependency>
  172. <dependency>
  173. <groupId>com.github.axet</groupId>
  174. <artifactId>kaptcha</artifactId>
  175. <version>${kaptcha.version}</version>
  176. </dependency>
  177. <dependency>
  178. <groupId>io.springfox</groupId>
  179. <artifactId>springfox-swagger2</artifactId>
  180. <version>${swagger.version}</version>
  181. </dependency>
  182. <dependency>
  183. <groupId>io.springfox</groupId>
  184. <artifactId>springfox-swagger-ui</artifactId>
  185. <version>${swagger.version}</version>
  186. </dependency>
  187. <dependency>
  188. <groupId>com.qiniu</groupId>
  189. <artifactId>qiniu-java-sdk</artifactId>
  190. <version>${qiniu.version}</version>
  191. </dependency>
  192. <dependency>
  193. <groupId>com.aliyun.oss</groupId>
  194. <artifactId>aliyun-sdk-oss</artifactId>
  195. <version>${aliyun.oss.version}</version>
  196. </dependency>
  197. <dependency>
  198. <groupId>com.qcloud</groupId>
  199. <artifactId>cos_api</artifactId>
  200. <version>${qcloud.cos.version}</version>
  201. <exclusions>
  202. <exclusion>
  203. <groupId>org.slf4j</groupId>
  204. <artifactId>slf4j-log4j12</artifactId>
  205. </exclusion>
  206. </exclusions>
  207. </dependency>
  208. <dependency>
  209. <groupId>joda-time</groupId>
  210. <artifactId>joda-time</artifactId>
  211. <version>${joda.time.version}</version>
  212. </dependency>
  213. </dependencies>
  214. <build>
  215. <finalName>${project.artifactId}</finalName>
  216. <extensions>
  217. <extension>
  218. <groupId>org.apache.maven.wagon</groupId>
  219. <artifactId>wagon-ssh</artifactId>
  220. <version>2.8</version>
  221. </extension>
  222. </extensions>
  223. <plugins>
  224. <plugin>
  225. <groupId>org.springframework.boot</groupId>
  226. <artifactId>spring-boot-maven-plugin</artifactId>
  227. <configuration>
  228. <fork>true</fork>
  229. </configuration>
  230. </plugin>
  231. <!-- 跳过单元测试 -->
  232. <plugin>
  233. <groupId>org.apache.maven.plugins</groupId>
  234. <artifactId>maven-surefire-plugin</artifactId>
  235. <configuration>
  236. <skipTests>true</skipTests>
  237. </configuration>
  238. </plugin>
  239. <plugin>
  240. <groupId>org.codehaus.mojo</groupId>
  241. <artifactId>wagon-maven-plugin</artifactId>
  242. <version>1.0</version>
  243. <configuration>
  244. <fromFile>target/${pack-name}</fromFile>
  245. <url><![CDATA[scp://${remote-username}:${remote-passwd}@${remote-addr}${service-path}]]></url>
  246. <commands>
  247. <!-- Kill Old Process -->
  248. <command>pkill -f ${pack-name}</command>
  249. <command>rm -f ${service-path}/renren.log</command>
  250. <!-- Restart jar package,write result into renren.log -->
  251. <command><![CDATA[nohup java -jar ${service-path}/${pack-name} --spring.profiles.active=test > ${service-path}/renren.log 2>&1 & ]]></command>
  252. <command><![CDATA[netstat -nptl]]></command>
  253. <command><![CDATA[ps -ef | grep java | grep -v grep]]></command>
  254. </commands>
  255. <!-- 运行命令 mvn clean package wagon:upload-single wagon:sshexec-->
  256. <displayCommandOutputs>true</displayCommandOutputs>
  257. </configuration>
  258. </plugin>
  259. <plugin>
  260. <groupId>com.spotify</groupId>
  261. <artifactId>docker-maven-plugin</artifactId>
  262. <version>0.4.14</version>
  263. <!--<executions>-->
  264. <!--<execution>-->
  265. <!--<phase>package</phase>-->
  266. <!--<goals>-->
  267. <!--<goal>build</goal>-->
  268. <!--</goals>-->
  269. <!--</execution>-->
  270. <!--</executions>-->
  271. <configuration>
  272. <imageName>renren/fast</imageName>
  273. <dockerDirectory>${project.basedir}</dockerDirectory>
  274. <resources>
  275. <resource>
  276. <targetPath>/</targetPath>
  277. <directory>${project.build.directory}</directory>
  278. <include>${project.build.finalName}.jar</include>
  279. </resource>
  280. </resources>
  281. </configuration>
  282. <!-- 运行命令 mvn clean package docker:build 打包并生成docker镜像 -->
  283. </plugin>
  284. </plugins>
  285. </build>
  286. <repositories>
  287. <repository>
  288. <id>public</id>
  289. <name>aliyun nexus</name>
  290. <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
  291. <releases>
  292. <enabled>true</enabled>
  293. </releases>
  294. </repository>
  295. </repositories>
  296. <pluginRepositories>
  297. <pluginRepository>
  298. <id>public</id>
  299. <name>aliyun nexus</name>
  300. <url>http://maven.aliyun.com/nexus/content/groups/public/</url>
  301. <releases>
  302. <enabled>true</enabled>
  303. </releases>
  304. <snapshots>
  305. <enabled>false</enabled>
  306. </snapshots>
  307. </pluginRepository>
  308. </pluginRepositories>
  309. </project>