forked from RedHatWorkshops/camel-hello-world
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pom.xml
335 lines (311 loc) · 11.8 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
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
<?xml version="1.0"?>
<!--
Copyright 2005-2015 Red Hat, Inc.
Red Hat licenses this file to you under the Apache License, version
2.0 (the "License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied. See the License for the specific language governing
permissions and limitations under the License.
-->
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.jboss.fuse.openshift.examples</groupId>
<artifactId>camel-hello-world</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>bundle</packaging>
<name>Camel Hello World</name>
<description>Camel Hello World in custom JBoss Fuse/Karaf assembly</description>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<version.compiler.plugin>2.3.1</version.compiler.plugin>
<version.maven.bundle.plugin>2.3.7</version.maven.bundle.plugin>
<version.maven.resources.plugin>2.7</version.maven.resources.plugin>
<maven.compiler.target>1.7</maven.compiler.target>
<maven.compiler.source>1.7</maven.compiler.source>
<!-- versions for use in mvn plugins as we cannot inherit them from a BOM -->
<fabric8.version>2.2.55</fabric8.version>
<docker.maven.plugin.version>0.13.2</docker.maven.plugin.version>
<camel.version>2.16.0</camel.version>
<karaf.version>2.4.3</karaf.version>
<karaf.plugin.version>4.0.1</karaf.plugin.version>
<docker.from>fabric8/s2i-karaf:1.1.5</docker.from>
<fabric8.dockerPrefix>docker.io/</fabric8.dockerPrefix>
<fabric8.dockerUser>fabric8/</fabric8.dockerUser>
<docker.image>${fabric8.dockerPrefix}${fabric8.dockerUser}quickstart-karaf4-camellog:${project.version}</docker.image>
<docker.assemblyDescriptor>${project.build.directory}/fabric8/assembly.xml</docker.assemblyDescriptor>
<docker.port.container.jolokia>8778</docker.port.container.jolokia>
<docker.port.container.http>8181</docker.port.container.http>
<docker.baseDirectory>/opt/jboss/karaf</docker.baseDirectory>
<fabric8.label.component>${project.artifactId}</fabric8.label.component>
<fabric8.label.container>karaf4</fabric8.label.container>
<fabric8.label.group>quickstarts</fabric8.label.group>
<fabric8.iconRef>camel</fabric8.iconRef>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>io.fabric8</groupId>
<artifactId>fabric8-project</artifactId>
<version>${fabric8.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-blueprint</artifactId>
</dependency>
<!-- Karaf microcontainer dependencies -->
<dependency>
<!-- scope is compile so all features (there is only one) are installed into startup.properties,
and the feature repo itself is not added in etc/org.apache.karaf.features.cfg file -->
<groupId>org.apache.karaf.features</groupId>
<artifactId>static</artifactId>
<version>${karaf.plugin.version}</version>
<type>kar</type>
</dependency>
<dependency>
<groupId>org.apache.karaf.assemblies.features</groupId>
<artifactId>standard</artifactId>
<version>${karaf.version}</version>
<classifier>features</classifier>
<type>xml</type>
</dependency>
<dependency>
<groupId>org.apache.camel.karaf</groupId>
<artifactId>apache-camel</artifactId>
<classifier>features</classifier>
<type>xml</type>
</dependency>
</dependencies>
<build>
<finalName>${project.artifactId}</finalName>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
<plugins>
<!-- Compiler plugin enforces Java 1.7 compatibility and activates annotation processors -->
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>${version.compiler.plugin}</version>
<configuration>
<source>${maven.compiler.source}</source>
<target>${maven.compiler.target}</target>
</configuration>
</plugin>
<plugin>
<groupId>io.fabric8</groupId>
<artifactId>fabric8-maven-plugin</artifactId>
<version>${fabric8.version}</version>
<executions>
<execution>
<id>json</id>
<phase>generate-resources</phase>
<goals>
<goal>json</goal>
</goals>
</execution>
<execution>
<id>attach</id>
<phase>package</phase>
<goals>
<goal>attach</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>${version.maven.resources.plugin}</version>
<executions>
<execution>
<id>filter-extra-resources</id>
<goals>
<goal>copy-resources</goal>
</goals>
<phase>process-resources</phase>
<configuration>
<outputDirectory>${project.build.directory}/fabric8</outputDirectory>
<resources>
<resource>
<directory>src/main/fabric8</directory>
<filtering>true</filtering>
</resource>
</resources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<version>${version.maven.bundle.plugin}</version>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>org.apache.karaf.tooling</groupId>
<artifactId>karaf-maven-plugin</artifactId>
<version>${karaf.plugin.version}</version>
<extensions>true</extensions>
<executions>
<execution>
<id>karaf-assembly</id>
<goals>
<goal>assembly</goal>
</goals>
<phase>install</phase>
</execution>
<execution>
<id>karaf-archive</id>
<goals>
<goal>archive</goal>
</goals>
<phase>install</phase>
</execution>
</executions>
<configuration>
<!-- do not include build output directory -->
<karafVersion>v24</karafVersion>
<useReferenceUrls>true</useReferenceUrls>
<includeBuildOutputDirectory>false</includeBuildOutputDirectory>
<!-- no startupFeatures -->
<startupFeatures>
<feature>karaf-framework</feature>
<feature>shell</feature>
<feature>jaas</feature>
<feature>aries-blueprint</feature>
<feature>camel-blueprint</feature>
</startupFeatures>
<startupBundles>
<bundle>mvn:${project.groupId}/${project.artifactId}/${project.version}</bundle>
</startupBundles>
<blacklistedBundles>
<bundle>mvn:org.ops4j.pax.logging/pax-logging-api/1.8.4</bundle>
<bundle>mvn:org.ops4j.pax.logging/pax-logging-service/1.8.4</bundle>
</blacklistedBundles>
<libraries>
<library>
mvn:org.apache.karaf.jaas/org.apache.karaf.jaas.boot/${karaf.version};type:=boot;export:=true;delegate:=true
</library>
</libraries>
</configuration>
</plugin>
<plugin>
<groupId>org.jolokia</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>${docker.maven.plugin.version}</version>
<configuration>
<images>
<image>
<name>${docker.image}</name>
<build>
<tags>
<tag>latest</tag>
<tag>${project.version}</tag>
</tags>
<assembly>
<dockerFileDir>${project.build.directory}/fabric8/docker</dockerFileDir>
<basedir>/opt/jboss</basedir>
<inline xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
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>${project.artifactId}</id>
<files>
<!-- copy karaf archive -->
<file>
<source>${project.build.directory}/${project.artifactId}-${project.version}.tar.gz</source>
<outputDirectory>/</outputDirectory>
</file>
</files>
</inline>
</assembly>
</build>
</image>
</images>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>docker-build</id>
<build>
<plugins>
<plugin>
<groupId>org.jolokia</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>${docker.maven.plugin.version}</version>
<executions>
<execution>
<goals>
<goal>build</goal>
</goals>
<phase>package</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>docker-push</id>
<build>
<plugins>
<plugin>
<groupId>org.jolokia</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>${docker.maven.plugin.version}</version>
<executions>
<execution>
<goals>
<goal>build</goal>
<goal>push</goal>
</goals>
<phase>package</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
<repositories>
<repository>
<id>oss-sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
<name>OSS Sonatype Nexus Snapshots</name>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>oss-sonatype-snapshots</id>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
<name>OSS Sonatype Nexus Snapshots</name>
<releases>
<enabled>false</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</project>