This repository has been archived by the owner on May 10, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
/
pom.xml
205 lines (194 loc) · 9.33 KB
/
pom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.dukecon</groupId>
<artifactId>dukecon-server-docker</artifactId>
<version>1.4-SNAPSHOT</version>
<packaging>pom</packaging>
<scm>
<url>https://github.com/dukecon/dukecon_server_docker.git</url>
<connection>scm:git:[email protected]:dukecon/dukecon_server_docker.git</connection>
</scm>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<!-- Set this to localhost if you would like to test upload server -->
<nexus.repository.host>dev.dukecon.org</nexus.repository.host>
<nexus.repository.port />
<nexus.repository.base>/nexus</nexus.repository.base>
<!--Versions of Plugins and Dependencies-->
<docker-maven-plugin.version>0.23.0</docker-maven-plugin.version>
<!-- Max 120 seconds to wait until docker start finished -->
<uptime-max>120000</uptime-max>
<dukecon.version>${project.version}</dukecon.version>
</properties>
<repositories>
<repository>
<id>dukecon</id>
<url>http://${nexus.repository.host}${nexus.repository.port}${nexus.repository.base}/content/groups/public</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>dukecon</id>
<url>http://${nexus.repository.host}${nexus.repository.port}${nexus.repository.base}/content/groups/public</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
<distributionManagement>
<snapshotRepository>
<id>dukecon-snapshots</id>
<name>DukeCon Snapshots</name>
<url>http://${nexus.repository.host}${nexus.repository.port}${nexus.repository.base}/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>dukecon-releases</id>
<name>DukeCon Releases</name>
<url>http://${nexus.repository.host}${nexus.repository.port}${nexus.repository.base}/content/repositories/releases</url>
</repository>
</distributionManagement>
<dependencies>
<dependency>
<groupId>org.dukecon</groupId>
<artifactId>dukecon-server-springboot</artifactId>
<version>${dukecon.version}</version>
<type>war</type>
</dependency>
</dependencies>
<profiles>
<profile>
<id>release</id>
<properties>
<dukecon.version>[1.4.0,1.5.0)</dukecon.version>
</properties>
</profile>
</profiles>
<build>
<defaultGoal>docker:build</defaultGoal>
<pluginManagement>
<plugins>
<plugin>
<groupId>com.github.danielflower.mavenplugins</groupId>
<artifactId>multi-module-maven-release-plugin</artifactId>
<version>DC-1.5-SNAPSHOT</version>
<configuration>
<resolveSnapshots>
<!-- TODO: allow for usage of a version property -->
<resolveSnapshot>org.dukecon:dukecon-server-springboot1.4-SNAPSHOT</resolveSnapshot>
</resolveSnapshots>
</configuration>
</plugin>
<plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>${docker-maven-plugin.version}</version>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<groupId>com.github.danielflower.mavenplugins</groupId>
<artifactId>multi-module-maven-release-plugin</artifactId>
</plugin>
<plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<configuration>
<imagePullPolicy>always</imagePullPolicy>
<images>
<image>
<name>dukecon/dukecon-server:${project.version}</name>
<build>
<from>openjdk:8-jre-alpine</from>
<maintainer>[email protected]</maintainer>
<tags>
<tag>${project.version}</tag>
<tag>latest</tag>
</tags>
<ports>
<port>8080</port>
</ports>
<volumes>
<volume>/var/cache/dukecon</volume>
</volumes>
<env>
<JAVA_DEFAULT_OPTS>-Xms768M -Xmx1536M</JAVA_DEFAULT_OPTS>
</env>
<cmd>
<shell>java -Djava.security.egd=file:/dev/./urandom ${JAVA_DEFAULT_OPTS} ${JAVA_OPTS} -jar /opt/dukecon/dukecon.war ${DUKECON_ARGS}</shell>
</cmd>
<workdir>/opt/dukecon</workdir>
<cleanup>false</cleanup>
<assembly>
<basedir>/opt/dukecon</basedir>
<inline xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2" xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">
<id>dukecon-server</id>
<dependencySets>
<dependencySet>
<includes>
<include>org.dukecon:dukecon-server-springboot</include>
</includes>
<outputDirectory>.</outputDirectory>
<outputFileNameMapping>dukecon.war</outputFileNameMapping>
</dependencySet>
</dependencySets>
</inline>
</assembly>
</build>
<run>
<ports>
<!-- Port mappings: Container internal
port (which must be exposed) will be dynamically mapped and this (random)
port will be assigned to the maven variable ${tomcat.port}. Multiple port
mapping can be specified here -->
<port>dukecon.port:8080</port>
</ports>
<env>
<DUKECON_ARGS>--conferences.file=conferences-integrationtest.yml</DUKECON_ARGS>
</env>
<wait>
<!-- The plugin waits until this URL is reachable via HTTP ... -->
<url>http://${docker.host.address}:${dukecon.port}/health</url>
<time>${uptime-max}</time>
</wait>
<log>
<color>BLUE</color>
<file>docker.log</file>
</log>
</run>
</image>
</images>
</configuration>
<!-- Connect this plugin to the maven lifecycle around the
integration-test phase. I.e. start the container in pre-integration-test
and stop it in post-integration-test. -->
<executions>
<execution>
<id>start</id>
<phase>pre-integration-test</phase>
<goals>
<goal>build</goal>
<goal>start</goal>
</goals>
</execution>
<execution>
<id>stop</id>
<phase>post-integration-test</phase>
<goals>
<goal>stop</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>