pom.xml 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541
  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. <artifactId>platform-manage</artifactId>
  5. <packaging>war</packaging>
  6. <name>platform-manage Maven Webapp</name>
  7. <url>http://maven.apache.org</url>
  8. <parent>
  9. <groupId>com.uas.platform</groupId>
  10. <artifactId>platform</artifactId>
  11. <version>0.0.1-SNAPSHOT</version>
  12. <relativePath>../platform</relativePath>
  13. </parent>
  14. <profiles>
  15. <profile>
  16. <!-- 开发环境 -->
  17. <id>dev</id>
  18. <properties>
  19. <profile>dev</profile>
  20. </properties>
  21. </profile>
  22. <profile>
  23. <!-- 测试环境 -->
  24. <id>test</id>
  25. <properties>
  26. <profile>test</profile>
  27. </properties>
  28. </profile>
  29. <profile>
  30. <!-- 生产环境 -->
  31. <id>prod</id>
  32. <properties>
  33. <profile>prod</profile>
  34. </properties>
  35. <!-- 默认 -->
  36. <activation>
  37. <activeByDefault>true</activeByDefault>
  38. </activation>
  39. </profile>
  40. </profiles>
  41. <dependencies>
  42. <dependency>
  43. <groupId>javax.servlet</groupId>
  44. <artifactId>servlet-api</artifactId>
  45. </dependency>
  46. <dependency>
  47. <groupId>junit</groupId>
  48. <artifactId>junit</artifactId>
  49. <scope>test</scope>
  50. </dependency>
  51. <dependency>
  52. <groupId>log4j</groupId>
  53. <artifactId>log4j</artifactId>
  54. </dependency>
  55. <dependency>
  56. <groupId>com.uas.platform</groupId>
  57. <artifactId>platform-core</artifactId>
  58. </dependency>
  59. <!-- spring -->
  60. <dependency>
  61. <groupId>org.springframework</groupId>
  62. <artifactId>spring-core</artifactId>
  63. <exclusions>
  64. <exclusion>
  65. <groupId>commons-logging</groupId>
  66. <artifactId>commons-logging</artifactId>
  67. </exclusion>
  68. </exclusions>
  69. </dependency>
  70. <dependency>
  71. <groupId>org.springframework</groupId>
  72. <artifactId>spring-context</artifactId>
  73. </dependency>
  74. <dependency>
  75. <groupId>org.springframework</groupId>
  76. <artifactId>spring-context-support</artifactId>
  77. </dependency>
  78. <dependency>
  79. <groupId>org.springframework</groupId>
  80. <artifactId>spring-webmvc</artifactId>
  81. </dependency>
  82. <dependency>
  83. <groupId>org.springframework</groupId>
  84. <artifactId>spring-jdbc</artifactId>
  85. </dependency>
  86. <dependency>
  87. <groupId>org.springframework</groupId>
  88. <artifactId>spring-tx</artifactId>
  89. </dependency>
  90. <dependency>
  91. <groupId>org.springframework</groupId>
  92. <artifactId>spring-aop</artifactId>
  93. </dependency>
  94. <dependency>
  95. <groupId>org.springframework</groupId>
  96. <artifactId>spring-aspects</artifactId>
  97. </dependency>
  98. <!-- jpa -->
  99. <dependency>
  100. <groupId>org.springframework.data</groupId>
  101. <artifactId>spring-data-jpa</artifactId>
  102. </dependency>
  103. <!-- -->
  104. <dependency>
  105. <groupId>commons-fileupload</groupId>
  106. <artifactId>commons-fileupload</artifactId>
  107. <version>1.3.1</version>
  108. </dependency>
  109. <!-- hibernate -->
  110. <dependency>
  111. <groupId>org.hibernate</groupId>
  112. <artifactId>hibernate-core</artifactId>
  113. </dependency>
  114. <dependency>
  115. <groupId>org.hibernate</groupId>
  116. <artifactId>hibernate-entitymanager</artifactId>
  117. <exclusions>
  118. <exclusion>
  119. <groupId>cglib</groupId>
  120. <artifactId>cglib</artifactId>
  121. </exclusion>
  122. <exclusion>
  123. <groupId>dom4j</groupId>
  124. <artifactId>dom4j</artifactId>
  125. </exclusion>
  126. </exclusions>
  127. </dependency>
  128. <dependency>
  129. <groupId>org.hibernate.javax.persistence</groupId>
  130. <artifactId>hibernate-jpa-2.1-api</artifactId>
  131. </dependency>
  132. <dependency>
  133. <groupId>commons-collections</groupId>
  134. <artifactId>commons-collections</artifactId>
  135. </dependency>
  136. <dependency>
  137. <groupId>org.hibernate</groupId>
  138. <artifactId>hibernate-validator</artifactId>
  139. </dependency>
  140. <dependency>
  141. <groupId>org.slf4j</groupId>
  142. <artifactId>slf4j-api</artifactId>
  143. </dependency>
  144. <dependency>
  145. <groupId>org.slf4j</groupId>
  146. <artifactId>jcl-over-slf4j</artifactId>
  147. </dependency>
  148. <dependency>
  149. <groupId>org.slf4j</groupId>
  150. <artifactId>slf4j-log4j12</artifactId>
  151. </dependency>
  152. <dependency>
  153. <groupId>org.aspectj</groupId>
  154. <artifactId>aspectjrt</artifactId>
  155. </dependency>
  156. <dependency>
  157. <groupId>org.aspectj</groupId>
  158. <artifactId>aspectjweaver</artifactId>
  159. </dependency>
  160. <dependency>
  161. <groupId>org.apache.commons</groupId>
  162. <artifactId>commons-lang3</artifactId>
  163. </dependency>
  164. <dependency>
  165. <groupId>javax.validation</groupId>
  166. <artifactId>validation-api</artifactId>
  167. </dependency>
  168. <dependency>
  169. <groupId>javax.transaction</groupId>
  170. <artifactId>jta</artifactId>
  171. </dependency>
  172. <dependency>
  173. <groupId>org.hibernate</groupId>
  174. <artifactId>hibernate-ehcache</artifactId>
  175. </dependency>
  176. <!-- jdbc -->
  177. <dependency>
  178. <groupId>com.oracle</groupId>
  179. <artifactId>ojdbc6</artifactId>
  180. </dependency>
  181. <dependency>
  182. <groupId>org.springframework</groupId>
  183. <artifactId>spring-orm</artifactId>
  184. </dependency>
  185. <dependency>
  186. <groupId>com.alibaba</groupId>
  187. <artifactId>druid</artifactId>
  188. </dependency>
  189. <!-- sendMsg -->
  190. <dependency>
  191. <groupId>org.apache.axis</groupId>
  192. <artifactId>axis-jaxrpc</artifactId>
  193. <version>1.4</version>
  194. </dependency>
  195. <dependency>
  196. <groupId>commons-discovery</groupId>
  197. <artifactId>commons-discovery</artifactId>
  198. <version>0.4</version>
  199. </dependency>
  200. <dependency>
  201. <groupId>com.ibm</groupId>
  202. <artifactId>wsdl4j</artifactId>
  203. <version>1.4</version>
  204. </dependency>
  205. <!-- spring mobile -->
  206. <dependency>
  207. <groupId>org.springframework.mobile</groupId>
  208. <artifactId>spring-mobile-device</artifactId>
  209. </dependency>
  210. <!--json-lib -->
  211. <dependency>
  212. <groupId>net.sf.json-lib</groupId>
  213. <artifactId>json-lib</artifactId>
  214. <classifier>jdk15</classifier>
  215. </dependency>
  216. <dependency>
  217. <groupId>org.codehaus.jackson</groupId>
  218. <artifactId>jackson-core-asl</artifactId>
  219. </dependency>
  220. <dependency>
  221. <groupId>org.codehaus.jackson</groupId>
  222. <artifactId>jackson-mapper-asl</artifactId>
  223. </dependency>
  224. <dependency>
  225. <groupId>com.fasterxml.jackson.core</groupId>
  226. <artifactId>jackson-core</artifactId>
  227. </dependency>
  228. <dependency>
  229. <groupId>com.fasterxml.jackson.core</groupId>
  230. <artifactId>jackson-databind</artifactId>
  231. </dependency>
  232. <dependency>
  233. <groupId>com.fasterxml.jackson.core</groupId>
  234. <artifactId>jackson-annotations</artifactId>
  235. </dependency>
  236. <dependency>
  237. <groupId>com.alibaba</groupId>
  238. <artifactId>fastjson</artifactId>
  239. </dependency>
  240. <!-- velocity -->
  241. <dependency>
  242. <groupId>org.apache.velocity</groupId>
  243. <artifactId>velocity</artifactId>
  244. </dependency>
  245. <!-- mail -->
  246. <dependency>
  247. <groupId>javax.mail</groupId>
  248. <artifactId>mail</artifactId>
  249. </dependency>
  250. <!-- ssh2 -->
  251. <dependency>
  252. <groupId>ch.ethz.ganymed</groupId>
  253. <artifactId>ganymed-ssh2</artifactId>
  254. <version>262</version>
  255. </dependency>
  256. <!-- redis -->
  257. <dependency>
  258. <groupId>redis.clients</groupId>
  259. <artifactId>jedis</artifactId>
  260. <version>2.7.3</version>
  261. </dependency>
  262. <dependency>
  263. <groupId>org.springframework.data</groupId>
  264. <artifactId>spring-data-redis</artifactId>
  265. <version>1.6.0.RELEASE</version>
  266. </dependency>
  267. <dependency>
  268. <groupId>org.apache.commons</groupId>
  269. <artifactId>commons-compress</artifactId>
  270. </dependency>
  271. <dependency>
  272. <groupId>com.uas.account</groupId>
  273. <artifactId>account-common</artifactId>
  274. </dependency>
  275. <dependency>
  276. <groupId>com.uas.dfs</groupId>
  277. <artifactId>dfs-api</artifactId>
  278. </dependency>
  279. <dependency>
  280. <groupId>com.caucho</groupId>
  281. <artifactId>hessian</artifactId>
  282. </dependency>
  283. <dependency>
  284. <groupId>com.alibaba</groupId>
  285. <artifactId>dubbo</artifactId>
  286. <exclusions>
  287. <exclusion>
  288. <groupId>javax.servlet</groupId>
  289. <artifactId>javax.servlet-api</artifactId>
  290. </exclusion>
  291. <exclusion>
  292. <groupId>org.apache.httpcomponents</groupId>
  293. <artifactId>httpcore</artifactId>
  294. </exclusion>
  295. </exclusions>
  296. </dependency>
  297. <dependency>
  298. <groupId>org.apache.zookeeper</groupId>
  299. <artifactId>zookeeper</artifactId>
  300. </dependency>
  301. <dependency>
  302. <groupId>com.github.sgroschupf</groupId>
  303. <artifactId>zkclient</artifactId>
  304. </dependency>
  305. <dependency>
  306. <groupId>com.uas.message</groupId>
  307. <artifactId>message-mail-api</artifactId>
  308. </dependency>
  309. <dependency>
  310. <groupId>com.belerweb</groupId>
  311. <artifactId>pinyin4j</artifactId>
  312. </dependency>
  313. <!-- phabricator接口 -->
  314. <dependency>
  315. <groupId>com.uas.phabricator</groupId>
  316. <artifactId>phabricator-api</artifactId>
  317. <version>0.0.1</version>
  318. </dependency>
  319. </dependencies>
  320. <build>
  321. <finalName>platform-manage</finalName>
  322. <!-- 受profile影响的目录 -->
  323. <resources>
  324. <resource>
  325. <directory>${basedir}/src/main/resources</directory>
  326. <filtering>true</filtering>
  327. <excludes>
  328. <exclude>**/*.xls</exclude>
  329. </excludes>
  330. </resource>
  331. <!-- xls文件不能filter处理,需区分出来 -->
  332. <resource>
  333. <directory>${basedir}/src/main/resources</directory>
  334. <filtering>false</filtering>
  335. <includes>
  336. <include>**/*.xls</include>
  337. </includes>
  338. </resource>
  339. </resources>
  340. <!-- 在maven生命周期validate阶段生成timestamp -->
  341. <plugins>
  342. <plugin>
  343. <groupId>org.codehaus.mojo</groupId>
  344. <artifactId>buildnumber-maven-plugin</artifactId>
  345. <version>1.3</version>
  346. <executions>
  347. <execution>
  348. <phase>validate</phase>
  349. <goals>
  350. <goal>create-timestamp</goal>
  351. </goals>
  352. </execution>
  353. </executions>
  354. <configuration>
  355. <configuration>
  356. <format>{0,date,yyyy-MM-dd HH:mm:ss}</format>
  357. <items>
  358. <item>timestamp</item>
  359. </items>
  360. </configuration>
  361. </configuration>
  362. </plugin>
  363. <plugin>
  364. <groupId>org.apache.maven.plugins</groupId>
  365. <artifactId>maven-compiler-plugin</artifactId>
  366. <configuration>
  367. <source>1.7</source>
  368. <target>1.7</target>
  369. </configuration>
  370. </plugin>
  371. <plugin>
  372. <groupId>com.samaxes.maven</groupId>
  373. <artifactId>minify-maven-plugin</artifactId>
  374. <version>1.7.4</version>
  375. <!-- 静态文件压缩 -->
  376. <executions>
  377. <execution>
  378. <id>default-minify</id>
  379. <phase>prepare-package</phase>
  380. <configuration>
  381. <charset>UTF-8</charset>
  382. <skipMerge>true</skipMerge>
  383. <closureLanguage>ECMASCRIPT5</closureLanguage>
  384. <closureAngularPass>true</closureAngularPass>
  385. <nosuffix>true</nosuffix>
  386. <webappTargetDir>${project.build.directory}/minify</webappTargetDir>
  387. <cssSourceDir>resources</cssSourceDir>
  388. <cssEngine>YUI</cssEngine>
  389. <jsSourceDir>resources</jsSourceDir>
  390. <jsEngine>CLOSURE</jsEngine>
  391. <cssSourceIncludes>
  392. <cssSourceInclude>css/**/*.css</cssSourceInclude>
  393. <cssSourceInclude>data/**/*.json</cssSourceInclude>
  394. </cssSourceIncludes>
  395. <cssSourceExcludes>
  396. <cssSourceExclude>css/**/*.min.css</cssSourceExclude>
  397. </cssSourceExcludes>
  398. <jsSourceIncludes>
  399. <jsSourceInclude>js/**/*.js</jsSourceInclude>
  400. </jsSourceIncludes>
  401. <jsSourceExcludes>
  402. <jsSourceExclude>js/**/*.min.js</jsSourceExclude>
  403. </jsSourceExcludes>
  404. </configuration>
  405. <goals>
  406. <goal>minify</goal>
  407. </goals>
  408. </execution>
  409. </executions>
  410. </plugin>
  411. <plugin>
  412. <artifactId>maven-resources-plugin</artifactId>
  413. <executions>
  414. <execution>
  415. <id>copy-resources</id>
  416. <phase>prepare-package</phase>
  417. <goals>
  418. <goal>copy-resources</goal>
  419. </goals>
  420. <configuration>
  421. <outputDirectory>${project.build.directory}/minify</outputDirectory>
  422. <overwrite>false</overwrite>
  423. <resources>
  424. <resource>
  425. <directory>${basedir}/src/main/webapp</directory>
  426. </resource>
  427. </resources>
  428. </configuration>
  429. </execution>
  430. </executions>
  431. </plugin>
  432. <plugin>
  433. <groupId>com.uas.plugins</groupId>
  434. <artifactId>static-maven-plugin</artifactId>
  435. <version>0.0.2-SNAPSHOT</version>
  436. <!-- 静态资源分离 -->
  437. <executions>
  438. <execution>
  439. <id>default-static</id>
  440. <phase>prepare-package</phase>
  441. <configuration>
  442. <pathMatcher>static</pathMatcher>
  443. <staticUrl>static</staticUrl>
  444. <webappDir>${project.build.directory}/minify</webappDir>
  445. <sourceDir>/</sourceDir>
  446. <targetDir>${project.build.directory}/statics</targetDir>
  447. <staticDir>/</staticDir>
  448. <sourceIncludes>
  449. <sourceInclude>resources/js/**/*.js</sourceInclude>
  450. <sourceInclude>resources/data/**/*.json</sourceInclude>
  451. <sourceInclude>resources/tpl/**/*.html</sourceInclude>
  452. <sourceInclude>WEB-INF/views/**/*.html</sourceInclude>
  453. </sourceIncludes>
  454. <!-- http://static.ubtob.com/css/index.css?_v=1450321871828 -->
  455. <versionSuffix>
  456. <suffix>?_v=${timestamp}</suffix>
  457. <exclude>*/require.js,*.min.js,*.min.css</exclude>
  458. </versionSuffix>
  459. </configuration>
  460. <goals>
  461. <goal>static</goal>
  462. </goals>
  463. </execution>
  464. </executions>
  465. </plugin>
  466. <plugin>
  467. <groupId>org.apache.maven.plugins</groupId>
  468. <artifactId>maven-war-plugin</artifactId>
  469. <version>2.4</version>
  470. <configuration>
  471. <webResources>
  472. <resource>
  473. <directory>${project.build.directory}/statics</directory>
  474. </resource>
  475. <resource>
  476. <directory>${project.build.directory}/minify</directory>
  477. </resource>
  478. </webResources>
  479. </configuration>
  480. </plugin>
  481. </plugins>
  482. <pluginManagement>
  483. <plugins>
  484. <plugin>
  485. <groupId>org.eclipse.m2e</groupId>
  486. <artifactId>lifecycle-mapping</artifactId>
  487. <version>1.0.0</version>
  488. <configuration>
  489. <lifecycleMappingMetadata>
  490. <pluginExecutions>
  491. <pluginExecution>
  492. <pluginExecutionFilter>
  493. <groupId>
  494. org.codehaus.mojo
  495. </groupId>
  496. <artifactId>
  497. buildnumber-maven-plugin
  498. </artifactId>
  499. <versionRange>
  500. [1.3,)
  501. </versionRange>
  502. <goals>
  503. <goal>
  504. create-timestamp
  505. </goal>
  506. </goals>
  507. </pluginExecutionFilter>
  508. <action>
  509. <ignore></ignore>
  510. </action>
  511. </pluginExecution>
  512. </pluginExecutions>
  513. </lifecycleMappingMetadata>
  514. </configuration>
  515. </plugin>
  516. </plugins>
  517. </pluginManagement>
  518. </build>
  519. <distributionManagement>
  520. <!-- 发布release仓库 -->
  521. <repository>
  522. <id>platform-release</id>
  523. <name>platform-release</name>
  524. <url>http://10.10.101.21:8081/artifactory/libs-release-local</url>
  525. </repository>
  526. <!-- 发布快照版本 -->
  527. <snapshotRepository>
  528. <id>platform-snapshots</id>
  529. <name>platform-snapshots</name>
  530. <url>http://10.10.101.21:8081/artifactory/libs-snapshot-local</url>
  531. </snapshotRepository>
  532. </distributionManagement>
  533. </project>