pom.xml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387
  1. <?xml version="1.0"?>
  2. <project
  3. xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
  5. <modelVersion>4.0.0</modelVersion>
  6. <groupId>at.acdp.urweb</groupId>
  7. <artifactId>urweb</artifactId>
  8. <version>1.0-SNAPSHOT</version>
  9. <name>urweb</name>
  10. <packaging>bundle</packaging>
  11. <properties>
  12. <!--********************************************************************-->
  13. <!-- Note: Update this section with relevant meta data -->
  14. <!-- that comes along with your URCap -->
  15. <!--********************************************************************-->
  16. <!--******************* BEGINNING OF URCAP META DATA *******************-->
  17. <urcap.symbolicname>at.acdp.urweb</urcap.symbolicname>
  18. <urcap.vendor>cdp</urcap.vendor>
  19. <urcap.contactAddress>Seestadtstraße 27/10 1220 Wien</urcap.contactAddress>
  20. <urcap.copyright>Copyright (C) 2018 Center for Digital Production GmbH</urcap.copyright>
  21. <urcap.description>urweb description</urcap.description>
  22. <urcap.licenseType>Commercial</urcap.licenseType>
  23. <!--********************** END OF URCAP META DATA **********************-->
  24. <!--********************************************************************-->
  25. <!-- Host, username and password of the robot to be used when running "mvn install -Premote" -->
  26. <urcap.install.host></urcap.install.host>
  27. <urcap.install.username>root</urcap.install.username>
  28. <urcap.install.password>easybot</urcap.install.password>
  29. <!--Install path for the UR Sim-->
  30. <ursim.home></ursim.home>
  31. <!--Host and standard user/password for UR Sim running in a VM-->
  32. <ursimvm.install.host></ursimvm.install.host>
  33. <ursimvm.install.username>ur</ursimvm.install.username>
  34. <ursimvm.install.password>easybot</ursimvm.install.password>
  35. <embed-dep>*;scope=compile;type=!pom;inline=true</embed-dep>
  36. <unpack-bundle>false</unpack-bundle>
  37. </properties>
  38. <build>
  39. <plugins>
  40. <plugin>
  41. <groupId>org.apache.maven.plugins</groupId>
  42. <artifactId>maven-compiler-plugin</artifactId>
  43. <version>3.6.0</version>
  44. <configuration>
  45. <source>1.8</source>
  46. <target>1.8</target>
  47. </configuration>
  48. </plugin>
  49. <plugin>
  50. <artifactId>maven-jar-plugin</artifactId>
  51. <version>3.1.0</version>
  52. <configuration>
  53. <archive>
  54. <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
  55. </archive>
  56. </configuration>
  57. </plugin>
  58. <plugin>
  59. <artifactId>maven-resources-plugin</artifactId>
  60. <version>3.1.0</version>
  61. </plugin>
  62. <plugin>
  63. <groupId>org.apache.felix</groupId>
  64. <artifactId>maven-bundle-plugin</artifactId>
  65. <version>4.1.0</version>
  66. <extensions>true</extensions>
  67. <executions>
  68. <execution>
  69. <id>bundle-manifest</id>
  70. <phase>process-classes</phase>
  71. <goals>
  72. <goal>manifest</goal>
  73. </goals>
  74. </execution>
  75. </executions>
  76. <configuration>
  77. <instructions>
  78. <!--********** DO NOT MODIFY THE ENTRIES OF THIS SECTION **********-->
  79. <Bundle-Category>URCap</Bundle-Category>
  80. <Bundle-Activator>at.acdp.urweb.Activator</Bundle-Activator>
  81. <Bundle-Vendor>${urcap.vendor}</Bundle-Vendor>
  82. <Bundle-ContactAddress>${urcap.contactAddress}</Bundle-ContactAddress>
  83. <Bundle-Copyright>${urcap.copyright}</Bundle-Copyright>
  84. <Bundle-LicenseType>${urcap.licenseType}</Bundle-LicenseType>
  85. <Bundle-Description>${urcap.description}</Bundle-Description>
  86. <!--***************************************************************-->
  87. <Import-Package>
  88. com.ur.urcap.api*;version="[1.3.0,2.0.0)",
  89. *
  90. </Import-Package>
  91. <Embed-Dependency>*;scope=compile;type=!pom;inline=true</Embed-Dependency>
  92. </instructions>
  93. </configuration>
  94. </plugin>
  95. <plugin>
  96. <groupId>org.apache.maven.plugins</groupId>
  97. <artifactId>maven-antrun-plugin</artifactId>
  98. <executions>
  99. <execution>
  100. <id>server-copy</id>
  101. <goals>
  102. <goal>run</goal>
  103. </goals>
  104. <phase>install</phase>
  105. <configuration>
  106. <tasks>
  107. <echo message="Pushing to host..." />
  108. <scp file="target/${project.build.finalName}.jar" port="22" trust="true"
  109. todir="root:easybot@192.168.20.130:/programs/urweb.urcap"/>
  110. </tasks>
  111. </configuration>
  112. </execution>
  113. </executions>
  114. <dependencies>
  115. <dependency>
  116. <groupId>org.apache.ant</groupId>
  117. <artifactId>ant-jsch</artifactId>
  118. <version>1.10.5</version>
  119. </dependency>
  120. <dependency>
  121. <groupId>com.jcraft</groupId>
  122. <artifactId>jsch</artifactId>
  123. <version>0.1.54</version>
  124. </dependency>
  125. <dependency>
  126. <groupId>commons-net</groupId>
  127. <artifactId>commons-net</artifactId>
  128. <version>3.6</version>
  129. </dependency>
  130. <dependency>
  131. <groupId>ant</groupId>
  132. <artifactId>ant-commons-net</artifactId>
  133. <version>1.6.5</version>
  134. </dependency>
  135. </dependencies>
  136. </plugin>
  137. <!--<plugin>-->
  138. <!--<groupId>org.codehaus.mojo</groupId>-->
  139. <!--<artifactId>exec-maven-plugin</artifactId>-->
  140. <!--<version>1.1</version>-->
  141. <!--<executions>-->
  142. <!--&lt;!&ndash; generate URCap package after compiling &ndash;&gt;-->
  143. <!--<execution>-->
  144. <!--<id>package-urcap</id>-->
  145. <!--<phase>package</phase>-->
  146. <!--<goals>-->
  147. <!--<goal>exec</goal>-->
  148. <!--</goals>-->
  149. <!--<configuration>-->
  150. <!--<executable>cp</executable>-->
  151. <!--<commandlineArgs>target/${project.build.finalName}.jar target/${project.build.finalName}.urcap</commandlineArgs>-->
  152. <!--<workingDirectory>.</workingDirectory>-->
  153. <!--</configuration>-->
  154. <!--</execution>-->
  155. <!--</executions>-->
  156. <!--</plugin>-->
  157. <plugin>
  158. <artifactId>maven-assembly-plugin</artifactId>
  159. <configuration>
  160. <descriptors>
  161. <descriptor>assembly.xml</descriptor>
  162. </descriptors>
  163. </configuration>
  164. <executions>
  165. <execution>
  166. <phase>package</phase>
  167. <goals>
  168. <goal>single</goal>
  169. </goals>
  170. </execution>
  171. </executions>
  172. </plugin>
  173. </plugins>
  174. <extensions>
  175. <extension>
  176. <groupId>org.apache.maven.wagon</groupId>
  177. <artifactId>wagon-ssh</artifactId>
  178. <version>3.2.0</version>
  179. </extension>
  180. </extensions>
  181. </build>
  182. <dependencies>
  183. <dependency>
  184. <groupId>org.osgi</groupId>
  185. <artifactId>org.osgi.core</artifactId>
  186. <version>4.3.1</version>
  187. <scope>provided</scope>
  188. </dependency>
  189. <dependency>
  190. <groupId>com.ur.urcap</groupId>
  191. <artifactId>api</artifactId>
  192. <version>1.3.0</version>
  193. <scope>provided</scope>
  194. </dependency>
  195. <dependency>
  196. <artifactId>nanohttpd</artifactId>
  197. <groupId>org.nanohttpd</groupId>
  198. <version>2.3.2-SNAPSHOT</version>
  199. </dependency>
  200. <dependency>
  201. <artifactId>nanohttpd-websocket</artifactId>
  202. <groupId>org.nanohttpd</groupId>
  203. <version>2.3.2-SNAPSHOT</version>
  204. </dependency>
  205. <dependency>
  206. <artifactId>nanohttpd-webserver</artifactId>
  207. <groupId>org.nanohttpd</groupId>
  208. <version>2.3.2-SNAPSHOT</version>
  209. </dependency>
  210. <dependency>
  211. <groupId>com.eclipsesource.minimal-json</groupId>
  212. <artifactId>minimal-json</artifactId>
  213. <version>0.9.5</version>
  214. </dependency>
  215. <!-- https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api -->
  216. <dependency>
  217. <groupId>org.junit.jupiter</groupId>
  218. <artifactId>junit-jupiter-api</artifactId>
  219. <version>5.3.1</version>
  220. <scope>test</scope>
  221. </dependency>
  222. <dependency>
  223. <groupId>org.nanohttpd</groupId>
  224. <artifactId>nanohttpd-nanolets</artifactId>
  225. <version>2.3.2-SNAPSHOT</version>
  226. </dependency>
  227. <dependency>
  228. <groupId>org.slf4j</groupId>
  229. <artifactId>slf4j-api</artifactId>
  230. <version>1.7.25</version>
  231. </dependency>
  232. <dependency>
  233. <groupId>org.slf4j</groupId>
  234. <artifactId>slf4j-jdk14</artifactId>
  235. <version>1.7.25</version>
  236. </dependency>
  237. </dependencies>
  238. <profiles>
  239. <profile>
  240. <id>remote</id>
  241. <build>
  242. <plugins>
  243. <plugin>
  244. <groupId>org.codehaus.mojo</groupId>
  245. <artifactId>exec-maven-plugin</artifactId>
  246. <version>1.1</version>
  247. <executions>
  248. <execution>
  249. <id>remote-install-urcap</id>
  250. <phase>install</phase>
  251. <goals>
  252. <goal>exec</goal>
  253. </goals>
  254. <configuration>
  255. <executable>sshpass</executable>
  256. <commandlineArgs>-p ${urcap.install.password} scp -o StrictHostKeyChecking=no target/${project.build.finalName}.jar ${urcap.install.username}@${urcap.install.host}:/root/.urcaps/${urcap.symbolicname}.jar</commandlineArgs>
  257. <workingDirectory>.</workingDirectory>
  258. </configuration>
  259. </execution>
  260. <execution>
  261. <id>remote-restart-ui</id>
  262. <phase>install</phase>
  263. <goals>
  264. <goal>exec</goal>
  265. </goals>
  266. <configuration>
  267. <executable>sshpass</executable>
  268. <commandlineArgs>-p ${urcap.install.password} ssh ${urcap.install.username}@${urcap.install.host} pkill java</commandlineArgs>
  269. <workingDirectory>.</workingDirectory>
  270. </configuration>
  271. </execution>
  272. </executions>
  273. </plugin>
  274. </plugins>
  275. </build>
  276. </profile>
  277. <profile>
  278. <id>local</id>
  279. <build>
  280. <plugins>
  281. <plugin>
  282. <groupId>org.codehaus.mojo</groupId>
  283. <artifactId>exec-maven-plugin</artifactId>
  284. <version>1.1</version>
  285. <executions>
  286. <execution>
  287. <id>local-install-urcap</id>
  288. <phase>install</phase>
  289. <goals>
  290. <goal>exec</goal>
  291. </goals>
  292. <configuration>
  293. <executable>cp</executable>
  294. <commandlineArgs>target/${project.build.finalName}.jar ${user.home}/.urcaps/${urcap.symbolicname}.jar</commandlineArgs>
  295. <workingDirectory>.</workingDirectory>
  296. </configuration>
  297. </execution>
  298. </executions>
  299. </plugin>
  300. </plugins>
  301. </build>
  302. </profile>
  303. <profile>
  304. <id>ursim</id>
  305. <build>
  306. <plugins>
  307. <plugin>
  308. <groupId>org.codehaus.mojo</groupId>
  309. <artifactId>exec-maven-plugin</artifactId>
  310. <version>1.1</version>
  311. <executions>
  312. <execution>
  313. <id>ursim-install-urcap</id>
  314. <phase>install</phase>
  315. <goals>
  316. <goal>exec</goal>
  317. </goals>
  318. <configuration>
  319. <executable>cp</executable>
  320. <commandlineArgs>target/${project.build.finalName}.jar ${ursim.home}/.urcaps/${urcap.symbolicname}.jar</commandlineArgs>
  321. <workingDirectory>.</workingDirectory>
  322. </configuration>
  323. </execution>
  324. </executions>
  325. </plugin>
  326. </plugins>
  327. </build>
  328. </profile>
  329. <profile>
  330. <id>ursimvm</id>
  331. <build>
  332. <plugins>
  333. <plugin>
  334. <groupId>org.codehaus.mojo</groupId>
  335. <artifactId>exec-maven-plugin</artifactId>
  336. <version>1.1</version>
  337. <executions>
  338. <execution>
  339. <id>ursimvm-install-urcap</id>
  340. <phase>install</phase>
  341. <goals>
  342. <goal>exec</goal>
  343. </goals>
  344. <configuration>
  345. <executable>sshpass</executable>
  346. <commandlineArgs>-p ${ursimvm.install.password} scp -o StrictHostKeyChecking=no target/${project.build.finalName}.jar ${ursimvm.install.username}@${ursimvm.install.host}:/home/ur/ursim-current/.urcaps/${urcap.symbolicname}.jar</commandlineArgs>
  347. <workingDirectory>.</workingDirectory>
  348. </configuration>
  349. </execution>
  350. </executions>
  351. </plugin>
  352. </plugins>
  353. </build>
  354. </profile>
  355. </profiles>
  356. <repositories>
  357. <repository>
  358. <id>sonatype-snapshots</id>
  359. <url>https://oss.sonatype.org/content/repositories/snapshots</url>
  360. <snapshots>
  361. <enabled>true</enabled>
  362. </snapshots>
  363. </repository>
  364. </repositories>
  365. </project>