Keycloak

Форк
0
1172 строки · 53.9 Кб
1
<?xml version="1.0"?>
2
<!--
3
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
4
~ and other contributors as indicated by the @author tags.
5
~
6
~ Licensed under the Apache License, Version 2.0 (the "License");
7
~ you may not use this file except in compliance with the License.
8
~ You may obtain a copy of the License at
9
~
10
~ http://www.apache.org/licenses/LICENSE-2.0
11
~
12
~ Unless required by applicable law or agreed to in writing, software
13
~ distributed under the License is distributed on an "AS IS" BASIS,
14
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
~ See the License for the specific language governing permissions and
16
~ limitations under the License.
17
-->
18

19
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
20
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
21
    <parent>
22
        <groupId>org.keycloak.testsuite</groupId>
23
        <artifactId>integration-arquillian-tests</artifactId>
24
        <version>999.0.0-SNAPSHOT</version>
25
    </parent>
26
    <modelVersion>4.0.0</modelVersion>
27

28
    <artifactId>integration-arquillian-tests-base</artifactId>
29

30
    <name>Base TestSuite</name>
31
    
32
    <description></description>
33

34
    <properties>
35
        <arquillian.protocol.default>Servlet 3.0</arquillian.protocol.default>
36
        <cli.log.output>false</cli.log.output>
37
        <test.intermittent>false</test.intermittent>
38
        <exclude.test>-</exclude.test>
39
        <exclude.console>-</exclude.console>
40
        <exclude.account>-</exclude.account>
41
        <exclude.client>-</exclude.client>
42
        <!--exclude cluster tests by default, enabled by 'auth-server-*-cluster' profiles in tests/pom.xml-->
43
        <exclude.cluster>**/cluster/**/*Test.java</exclude.cluster>
44
        <exclude.crossdc>**/crossdc/**/*Test.java</exclude.crossdc>
45
        <mvel.version>2.4.0.Final</mvel.version>
46
        <systemrules.version>1.19.0</systemrules.version>
47
        <common.resources>${basedir}/../../servers/auth-server/common</common.resources>
48
        <maven-compiler-plugin.version>3.8.1</maven-compiler-plugin.version>
49
        <maven.compiler.release>11</maven.compiler.release>
50
        <maven.compiler.target>11</maven.compiler.target>
51
        <maven.compiler.source>11</maven.compiler.source>
52
    </properties>
53
    
54
    <dependencies>
55
        <dependency>
56
            <groupId>org.keycloak</groupId>
57
            <artifactId>keycloak-util-embedded-ldap</artifactId>
58
            <exclusions>
59
                <exclusion>
60
                    <groupId>org.bouncycastle</groupId>
61
                    <artifactId>bcprov-jdk15on</artifactId>
62
                </exclusion>
63
            </exclusions>
64
        </dependency>
65
        <dependency>
66
            <groupId>org.keycloak</groupId>
67
            <artifactId>keycloak-core</artifactId>
68
            <scope>test</scope>
69
            <type>test-jar</type>
70
        </dependency>
71
        <dependency>
72
            <groupId>commons-configuration</groupId>
73
            <artifactId>commons-configuration</artifactId>
74
            <version>1.10</version>
75
        </dependency>
76
        <dependency>
77
            <groupId>commons-io</groupId>
78
            <artifactId>commons-io</artifactId>
79
        </dependency>
80
        <dependency>
81
            <groupId>org.keycloak.testsuite</groupId>
82
            <artifactId>integration-arquillian-testsuite-providers</artifactId>
83
            <version>${project.version}</version>
84
        </dependency>
85
        <dependency>
86
            <groupId>org.keycloak.testsuite</groupId>
87
            <artifactId>integration-arquillian-testsuite-providers-deployment</artifactId>
88
            <version>${project.version}</version>
89
        </dependency>
90
        <dependency>
91
            <groupId>junit</groupId>
92
            <artifactId>junit</artifactId>
93
            <scope>compile</scope>
94
        </dependency>
95
        <dependency>
96
            <groupId>org.hamcrest</groupId>
97
            <artifactId>hamcrest</artifactId>
98
            <scope>compile</scope>
99
        </dependency>
100
        <dependency>
101
            <groupId>com.icegreen</groupId>
102
            <artifactId>greenmail</artifactId>
103
            <scope>compile</scope>
104
        </dependency>
105
        <dependency>
106
            <groupId>org.subethamail</groupId>
107
            <artifactId>subethasmtp</artifactId>
108
            <scope>compile</scope>
109
        </dependency>
110
        <dependency>
111
            <groupId>org.testcontainers</groupId>
112
            <artifactId>testcontainers</artifactId>
113
        </dependency>
114
        <dependency>
115
            <groupId>com.google.guava</groupId>
116
            <artifactId>guava</artifactId>
117
        </dependency>
118
        <dependency>
119
            <groupId>org.keycloak</groupId>
120
            <artifactId>keycloak-model-storage-services</artifactId>
121
        </dependency>
122
        <dependency>
123
            <groupId>org.keycloak.testsuite</groupId>
124
            <artifactId>integration-arquillian-servers-app-server-spi</artifactId>
125
            <version>${project.version}</version>
126
        </dependency>
127
        <dependency>
128
            <groupId>org.keycloak.testsuite</groupId>
129
            <artifactId>integration-arquillian-util</artifactId>
130
            <version>${project.version}</version>
131
        </dependency>
132
        <dependency>
133
            <groupId>org.mvel</groupId>
134
            <artifactId>mvel2</artifactId>
135
            <version>${mvel.version}</version>
136
        </dependency>
137
        <dependency>
138
            <groupId>org.apache.maven.resolver</groupId>
139
            <artifactId>maven-resolver-api</artifactId>
140
        </dependency>
141
        <dependency>
142
            <groupId>io.smallrye</groupId>
143
            <artifactId>jandex</artifactId>
144
            <version>${smallrye.jandex.version}</version>
145
        </dependency>
146
        <dependency>
147
            <groupId>com.github.stefanbirkner</groupId>
148
            <artifactId>system-rules</artifactId>
149
            <version>${systemrules.version}</version>
150
            <scope>test</scope>
151
        </dependency>
152
        <dependency>
153
            <groupId>org.infinispan</groupId>
154
            <artifactId>infinispan-server-hotrod-jakarta</artifactId>
155
        </dependency>
156
        <dependency>
157
            <groupId>org.keycloak</groupId>
158
            <artifactId>keycloak-saml-adapter-core</artifactId>
159
        </dependency>
160
        <dependency>
161
            <groupId>jakarta.xml.ws</groupId>
162
            <artifactId>jakarta.xml.ws-api</artifactId>
163
            <scope>provided</scope>
164
        </dependency>
165
        <dependency>
166
            <groupId>org.jboss.resteasy</groupId>
167
            <artifactId>resteasy-core</artifactId>
168
            <scope>provided</scope>
169
        </dependency>
170
        <dependency>
171
            <groupId>jakarta.ws.rs</groupId>
172
            <artifactId>jakarta.ws.rs-api</artifactId>
173
            <scope>provided</scope>
174
        </dependency>
175

176
        <!-- FIXME: Override in order to prevent NoClassDefFoundError: org/jboss/threads/AsyncFuture in ClientContainerController -->
177
        <dependency>
178
            <groupId>org.jboss.threads</groupId>
179
            <artifactId>jboss-threads</artifactId>
180
            <version>2.4.0.Final</version>
181
        </dependency>
182

183
        <dependency>
184
            <groupId>org.jboss.spec.javax.servlet</groupId>
185
            <artifactId>jboss-servlet-api_3.0_spec</artifactId>
186
            <scope>provided</scope>
187
        </dependency>
188

189
        <!-- Embedded Distribution -->
190
        <dependency>
191
            <groupId>org.keycloak</groupId>
192
            <artifactId>keycloak-junit5</artifactId>
193
            <version>${project.version}</version>
194
            <exclusions>
195
                <exclusion>
196
                    <groupId>*</groupId>
197
                    <artifactId>*</artifactId>
198
                </exclusion>
199
            </exclusions>
200
        </dependency>
201
    </dependencies>
202
    
203
    <build>
204
        <testResources>
205
            <testResource>
206
                <directory>src/test/resources</directory>
207
                <filtering>true</filtering>
208
                <includes>
209
                    <include>migration-test/*</include>
210
                    <include>authorization-test/*</include>
211
                </includes>
212
            </testResource>
213
            <testResource>
214
                <directory>src/test/resources</directory>
215
            </testResource>
216
        </testResources>
217
        <plugins>
218
            <plugin>
219
                <artifactId>maven-jar-plugin</artifactId>
220
                <version>2.2</version>
221
                <executions>
222
                    <execution>
223
                        <goals>
224
                            <goal>test-jar</goal>
225
                        </goals>
226
                    </execution>
227
                </executions>
228
            </plugin>
229

230
            <plugin>
231
                <groupId>org.codehaus.mojo</groupId>
232
                <artifactId>xml-maven-plugin</artifactId>
233
                <executions>
234
                    <execution>
235
                        <id>arquillian-default-protocol</id>
236
                        <phase>process-resources</phase>
237
                        <goals>
238
                            <goal>transform</goal>
239
                        </goals>
240
                        <configuration>
241
                            <transformationSets>
242
                                <transformationSet>
243
                                    <dir>src/test/resources</dir>
244
                                    <includes>
245
                                        <include>arquillian.xml</include>
246
                                    </includes>
247
                                    <stylesheet>src/test/resources/arquillian.xsl</stylesheet>
248
                                    <outputDir>${project.build.directory}/dependency</outputDir>
249
                                    <parameters>
250
                                        <parameter>
251
                                            <name>defaultProtocol</name>
252
                                            <value>${arquillian.protocol.default}</value>
253
                                        </parameter>
254
                                    </parameters>
255
                                </transformationSet>
256
                            </transformationSets>
257
                        </configuration>
258
                    </execution>
259
                </executions>
260
            </plugin>
261

262
            <plugin>
263
                <artifactId>maven-surefire-plugin</artifactId>
264
                <configuration>
265
                    <excludes>
266
                        <exclude>${exclude.test}</exclude>
267
                        <exclude>${exclude.console}</exclude>
268
                        <exclude>${exclude.account}</exclude>
269
                        <exclude>${exclude.client}</exclude>
270
                        <exclude>${exclude.cluster}</exclude>
271
                        <exclude>${exclude.crossdc}</exclude>
272
                    </excludes>
273
                    <systemPropertyVariables>
274
                        <com.mchange.v2.c3p0.VMID>testsuiteVmId</com.mchange.v2.c3p0.VMID>
275
                        <auth.server.db.host>${docker.container.testdb.ip}</auth.server.db.host>
276
                    </systemPropertyVariables>
277
                </configuration>
278
            </plugin>
279

280
            <plugin>
281
                <artifactId>maven-resources-plugin</artifactId>
282
                <executions>
283
                    <execution>
284
                        <id>copy-common-dependencies</id>
285
                        <phase>generate-resources</phase>
286
                        <goals>
287
                            <goal>copy-resources</goal>
288
                        </goals>
289
                        <configuration>
290
                            <outputDirectory>${project.build.directory}/dependency</outputDirectory>
291
                            <resources>
292
                                <resource>
293
                                    <directory>src/test/resources</directory>
294
                                    <includes>
295
                                        <include>wildfly-config.xml</include>
296
                                        <include>password-blacklists/**</include>
297
                                        <include>log4j.properties</include>
298
                                        <include>vault/**</include>
299
                                        <include>firefox-cookies-prefs.js</include>
300
                                    </includes>
301
                                </resource>
302
                            </resources>
303
                        </configuration>
304
                    </execution>
305
                    <execution>
306
                        <id>copy-admin-user-json-file</id>
307
                        <phase>process-resources</phase>
308
                        <goals>
309
                            <goal>copy-resources</goal>
310
                        </goals>
311
                        <configuration>
312
                            <skip>${skip.add.user.json}</skip>
313
                            <outputDirectory>${auth.server.config.dir}</outputDirectory>
314
                            <resources>
315
                                <resource>
316
                                    <directory>src/test/resources</directory>
317
                                    <includes>
318
                                        <include>keycloak-add-user.json</include>
319
                                    </includes>
320
                                    <filtering>true</filtering>
321
                                </resource>
322
                            </resources>
323
                        </configuration>
324
                    </execution>
325
                </executions>
326
            </plugin>
327

328
            <plugin>
329
                <artifactId>maven-dependency-plugin</artifactId>
330
                <executions>
331
                    <execution>
332
                        <id>unpack-client-cli-dist</id>
333
                        <phase>generate-test-resources</phase>
334
                        <goals>
335
                            <goal>unpack</goal>
336
                        </goals>
337
                        <configuration>
338
                            <artifactItems>
339
                                <artifactItem>
340
                                    <groupId>org.keycloak</groupId>
341
                                    <artifactId>keycloak-client-cli-dist</artifactId>
342
                                    <version>${project.version}</version>
343
                                    <type>zip</type>
344
                                    <outputDirectory>${containers.home}</outputDirectory>
345
                                </artifactItem>
346
                             </artifactItems>
347
                        </configuration>
348
                    </execution>
349
                    <execution>
350
                        <id>copy-testsuite-providers-to-base-testsuite</id>
351
                        <phase>generate-test-resources</phase>
352
                        <goals>
353
                            <goal>copy-dependencies</goal>
354
                        </goals>
355
                        <configuration>
356
                            <includeGroupIds>org.keycloak.testsuite</includeGroupIds>
357
                            <includeArtifactIds>integration-arquillian-testsuite-providers</includeArtifactIds>
358
                            <outputDirectory>${project.build.directory}/lib</outputDirectory>
359
                        </configuration>
360
                    </execution>
361
                </executions>
362
            </plugin>
363
            <plugin>
364
                <groupId>io.fabric8</groupId>
365
                <artifactId>docker-maven-plugin</artifactId>
366
                <version>${docker.maven.plugin.version}</version>
367
                <configuration>
368
                    <skip>${docker.database.skip}</skip>
369
                </configuration>
370
                <executions>
371
                    <execution>
372
                        <id>start-db-container</id>
373
                        <phase>process-test-classes</phase>
374
                        <goals>
375
                            <goal>start</goal>
376
                        </goals>
377
                        <configuration>
378
                            <showLogs>true</showLogs>
379
                            <images>
380
                                <image>
381
                                    <alias>testdb</alias>
382
                                    <name>${docker.database.image}</name>
383
                                    <run>
384
                                        <shmSize>${docker.database.shmsize}</shmSize>
385
                                        <ports>
386
                                            <port>${docker.database.port}:${docker.database.port}</port>
387
                                        </ports>
388
                                        <env>
389
                                            <!-- MYSQL and MariaDB -->
390
                                            <MYSQL_DATABASE>${keycloak.connectionsJpa.database}</MYSQL_DATABASE>
391
                                            <MYSQL_USER>${keycloak.connectionsJpa.user}</MYSQL_USER>
392
                                            <MYSQL_PASSWORD>${keycloak.connectionsJpa.password}</MYSQL_PASSWORD>
393
                                            <MYSQL_RANDOM_ROOT_PASSWORD>true</MYSQL_RANDOM_ROOT_PASSWORD>
394

395
                                            <!-- PostgreSQL -->
396
                                            <POSTGRES_DB>${keycloak.connectionsJpa.database}</POSTGRES_DB>
397
                                            <POSTGRES_USER>${keycloak.connectionsJpa.user}</POSTGRES_USER>
398
                                            <POSTGRES_PASSWORD>${keycloak.connectionsJpa.password}</POSTGRES_PASSWORD>
399

400
                                            <!-- MSSQL -->
401
                                            <ACCEPT_EULA>Y</ACCEPT_EULA>
402
                                            <SA_PASSWORD>${keycloak.connectionsJpa.password}</SA_PASSWORD>
403

404
                                            <!-- Oracle -->
405
                                            <ORACLE_SID>${keycloak.connectionsJpa.database}</ORACLE_SID>
406
                                            <ORACLE_PWD>sa</ORACLE_PWD>
407
                                        </env>
408
                                        <cmd>${docker.database.cmd}</cmd>
409
                                        <wait>
410
                                            <!-- Do not use waiting for port since that is unreliable, sometimes port is listening before DB is ready to serve -->
411
                                            <log>${docker.database.wait-for-log-regex}</log>
412
                                            <time>2000000</time>
413
                                            <kill>10000</kill>
414
                                            <exec>
415
                                              <postStart>${docker.database.postStart}</postStart>
416
                                              <breakOnError>true</breakOnError>
417
                                            </exec>
418
                                        </wait>
419
                                    </run>
420
                                </image>
421
                            </images>
422
                        </configuration>
423
                    </execution>
424
                    <execution>
425
                        <id>stop-db-container</id>
426
                        <phase>test</phase>
427
                        <goals>
428
                            <goal>stop</goal>
429
                        </goals>
430
                    </execution>
431
                </executions>
432
            </plugin>
433
            <plugin>
434
                <artifactId>maven-compiler-plugin</artifactId>
435
                <version>${maven-compiler-plugin.version}</version>
436
            </plugin>
437
        </plugins>
438

439
    </build>
440

441
    <profiles>
442
        <profile>
443
            <id>jpa</id>
444
            <build>
445
                <plugins>
446
                    <!-- DB will be released after the test -->
447
                    <plugin>
448
                        <groupId>org.keycloak</groupId>
449
                        <artifactId>db-allocator-plugin</artifactId>
450
                        <inherited>false</inherited>
451
                        <executions>
452
                            <execution>
453
                                <id>release-db</id>
454
                                <goals>
455
                                    <goal>release</goal>
456
                                </goals>
457
                            </execution>
458
                        </executions>
459
                    </plugin>
460
                </plugins>
461
            </build>
462
        </profile>
463

464
        <profile>
465
            <id>app-server-jetty94</id>
466
            <activation>
467
                <property>
468
                    <name>app.server</name>
469
                    <value>jetty94</value>
470
                </property>
471
            </activation>
472
            <properties>
473
                <app.server>jetty94</app.server> <!--in case the profile is called directly-->
474
                <app.server.skip.unpack>true</app.server.skip.unpack>
475
            </properties>
476
            <dependencies>
477
                <dependency>
478
                    <groupId>org.keycloak.testsuite</groupId>
479
                    <artifactId>integration-arquillian-servers-app-server-jetty-94</artifactId>
480
                    <version>${project.version}</version>
481
                    <scope>runtime</scope>
482
                </dependency>
483
            </dependencies>
484
            <build>
485
                <plugins>
486
                    <plugin>
487
                        <groupId>org.commonjava.maven.plugins</groupId>
488
                        <artifactId>directory-maven-plugin</artifactId>
489
                    </plugin>
490
                </plugins>
491
            </build>
492
        </profile>
493
        <profile>
494
            <id>app-server-undertow</id>
495
            <activation>
496
                <property>
497
                    <name>app.server</name>
498
                    <value>undertow</value>
499
                </property>
500
            </activation>
501
            <properties>
502
                <app.server>undertow</app.server> <!--in case the profile is called directly-->
503
            </properties>
504
            <dependencies>
505
                <dependency>
506
                    <groupId>org.keycloak.testsuite</groupId>
507
                    <artifactId>integration-arquillian-servers-app-server-undertow</artifactId>
508
                    <version>${project.version}</version>
509
                    <scope>runtime</scope>
510
                </dependency>
511
            </dependencies>
512
        </profile>
513
        <profile>
514
            <id>app-server-wildfly</id>
515
            <activation>
516
                <property>
517
                    <name>app.server</name>
518
                    <value>wildfly</value>
519
                </property>
520
            </activation>
521
            <properties>
522
                <app.server>wildfly</app.server> <!--in case the profile is called directly-->
523
                <app.server.skip.unpack>false</app.server.skip.unpack>
524
                <wildfly.core.version>${tests.wildfly.core.version}</wildfly.core.version>
525
            </properties>
526
            <dependencies>
527
                <dependency>
528
                    <groupId>org.keycloak.testsuite</groupId>
529
                    <artifactId>integration-arquillian-servers-app-server-wildfly</artifactId>
530
                    <version>${project.version}</version>
531
                    <scope>runtime</scope>
532
                </dependency>
533
                <!--required by creaper-core-->
534
                <dependency>
535
                    <groupId>org.wildfly.core</groupId>
536
                    <artifactId>wildfly-cli</artifactId>
537
                    <scope>test</scope>
538
                    <version>${wildfly.core.version}</version>
539
                </dependency>
540
            </dependencies>
541
            <build>
542
                <plugins>
543
                    <plugin>
544
                        <groupId>org.commonjava.maven.plugins</groupId>
545
                        <artifactId>directory-maven-plugin</artifactId>
546
                    </plugin>
547
                </plugins>
548
            </build>
549
        </profile>
550
        <profile>
551
            <id>app-server-eap</id>
552
            <activation>
553
                <property>
554
                    <name>app.server</name>
555
                    <value>eap</value>
556
                </property>
557
            </activation>
558
            <properties>
559
                <app.server>eap</app.server> <!--in case the profile is called directly-->
560
                <app.server.skip.unpack>false</app.server.skip.unpack>
561
                <wildfly.core.version>${tests.wildfly.core.version}</wildfly.core.version>
562
            </properties>
563
            <dependencies>
564
                <dependency>
565
                    <groupId>org.keycloak.testsuite</groupId>
566
                    <artifactId>integration-arquillian-servers-app-server-eap</artifactId>
567
                    <version>${project.version}</version>
568
                    <scope>runtime</scope>
569
                </dependency>
570
                <!--required by creaper-core-->
571
                <dependency>
572
                    <groupId>org.wildfly.core</groupId>
573
                    <artifactId>wildfly-cli</artifactId>
574
                    <scope>test</scope>
575
                    <version>${wildfly.core.version}</version>
576
                </dependency>
577
            </dependencies>
578
            <build>
579
                <plugins>
580
                    <plugin>
581
                        <groupId>org.commonjava.maven.plugins</groupId>
582
                        <artifactId>directory-maven-plugin</artifactId>
583
                    </plugin>
584
                </plugins>
585
            </build>
586
        </profile>
587

588
        <profile>
589
            <id>app-server-eap8</id>
590
            <activation>
591
                <property>
592
                    <name>app.server</name>
593
                    <value>eap8</value>
594
                </property>
595
            </activation>
596
            <properties>
597
                <app.server>eap8</app.server>
598
                <app.server.skip.unpack>false</app.server.skip.unpack>
599
                <app.server.artifactId>integration-arquillian-servers-app-server-jboss-galleon</app.server.artifactId>
600
                <arquillian.protocol.default>Servlet 5.0</arquillian.protocol.default>
601
                <wildfly.core.version>${tests.wildfly.core.version}</wildfly.core.version>
602
            </properties>
603
            <dependencies>
604
                <dependency>
605
                    <groupId>org.keycloak.testsuite</groupId>
606
                    <artifactId>integration-arquillian-servers-app-server-jboss-galleon</artifactId>
607
                    <version>${project.version}</version>
608
                    <scope>runtime</scope>
609
                </dependency>
610
                <!--required by creaper-core-->
611
                <dependency>
612
                    <groupId>org.wildfly.core</groupId>
613
                    <artifactId>wildfly-cli</artifactId>
614
                    <scope>test</scope>
615
                    <version>${wildfly.core.version}</version>
616
                </dependency>
617
            </dependencies>
618
            <build>
619
                <plugins>
620
                    <plugin>
621
                        <groupId>org.commonjava.maven.plugins</groupId>
622
                        <artifactId>directory-maven-plugin</artifactId>
623
                    </plugin>
624
                </plugins>
625
            </build>
626
        </profile>
627

628
        <profile>
629
            <id>app-server-eap71</id>
630
            <activation>
631
                <property>
632
                    <name>app.server</name>
633
                    <value>eap71</value>
634
                </property>
635
            </activation>
636
            <properties>
637
                <app.server>eap71</app.server> <!--in case the profile is called directly-->
638
                <app.server.skip.unpack>false</app.server.skip.unpack>
639
                <app.server.artifactId>integration-arquillian-servers-app-server-eap</app.server.artifactId><!-- Need to override -->
640
            </properties>
641
            <dependencies>
642
                <dependency>
643
                    <groupId>org.keycloak.testsuite</groupId>
644
                    <artifactId>integration-arquillian-servers-app-server-eap</artifactId>
645
                    <version>${project.version}</version>
646
                    <scope>runtime</scope>
647
                </dependency>
648
                <!--required by creaper-core-->
649
                <dependency>
650
                    <groupId>org.wildfly.core</groupId>
651
                    <artifactId>wildfly-cli</artifactId>
652
                    <scope>test</scope>
653
                    <version>3.0.10.Final</version>
654
                </dependency>
655
            </dependencies>
656
            <build>
657
                <plugins>
658
                    <plugin>
659
                        <groupId>org.commonjava.maven.plugins</groupId>
660
                        <artifactId>directory-maven-plugin</artifactId>
661
                    </plugin>
662
                </plugins>
663
            </build>
664
        </profile>
665
        <!-- EAP6, Fuse 6.x and Fuse 7.x adapter profiles, can be removed once there will be no need for supporting these adapters  -->
666
        <profile>
667
            <id>app-server-eap6</id>
668
            <activation>
669
                <property>
670
                    <name>app.server</name>
671
                    <value>eap6</value>
672
                </property>
673
            </activation>
674
            <properties>
675
                <app.server>eap6</app.server> <!--in case the profile is called directly-->
676
                <app.server.skip.unpack>false</app.server.skip.unpack>
677

678
                <arquillian-wildfly-container.version>2.0.0.Final</arquillian-wildfly-container.version>
679
                <!--TODO: check it when KEYCLOAK-8529 is resolved-->
680
                <!--<infinispan.version>8.2.5.Final</infinispan.version>     KEYCLOAK-5302 -->
681

682
                <app.server.management.protocol>remote</app.server.management.protocol>
683
                <app.server.management.port>10199</app.server.management.port>
684
                <app.server.1.management.port>10299</app.server.1.management.port>
685
                <app.server.2.management.port>10399</app.server.2.management.port>
686
            </properties>
687
            <dependencies>
688
                <dependency>
689
                    <groupId>org.keycloak.testsuite</groupId>
690
                    <artifactId>integration-arquillian-servers-app-server-eap6</artifactId>
691
                    <version>${project.version}</version>
692
                    <scope>runtime</scope>
693
                </dependency>
694
                <!--required by creaper-core-->
695
                <dependency>
696
                    <groupId>org.wildfly.core</groupId>
697
                    <artifactId>wildfly-cli</artifactId>
698
                    <scope>test</scope>
699
                    <version>2.0.10.Final</version>
700
                    <exclusions>
701
                        <exclusion>
702
                            <groupId>org.jboss.modules</groupId>
703
                            <artifactId>jboss-modules</artifactId>  
704
                        </exclusion>
705
                    </exclusions>
706
                </dependency>
707
            </dependencies>
708
            <build>
709
                <plugins>
710
                    <plugin>
711
                        <groupId>org.commonjava.maven.plugins</groupId>
712
                        <artifactId>directory-maven-plugin</artifactId>
713
                    </plugin>
714
                </plugins>
715
            </build>
716
        </profile>
717
        <profile>
718
            <id>app-server-fuse63</id>
719
            <activation>
720
                <property>
721
                    <name>app.server</name>
722
                    <value>fuse63</value>
723
                </property>
724
            </activation>
725
            <properties>
726
                <app.server>fuse63</app.server> <!--in case the profile is called directly-->
727
                <app.server.skip.unpack>false</app.server.skip.unpack>
728

729
                <!--fuse examples expect auth server on 8080-->
730
                <auth.server.port.offset>0</auth.server.port.offset>
731
                <auth.server.http.port>8080</auth.server.http.port>
732
                <auth.server.management.port>9990</auth.server.management.port>
733
                <!--fuse examples expect default karaf http port 8181-->
734
                <app.server.http.port>8181</app.server.http.port>
735

736
                <app.server.management.user>admin</app.server.management.user>
737
                <app.server.management.password>password</app.server.management.password>
738
                <app.server.karaf.jvm.debug.args>-agentlib:jdwp=transport=dt_socket,server=y,suspend=${app.server.debug.suspend},address=localhost:${app.server.debug.port}</app.server.karaf.jvm.debug.args>
739
            </properties>
740
            <dependencies>
741
                <dependency>
742
                    <groupId>org.keycloak.testsuite</groupId>
743
                    <artifactId>integration-arquillian-servers-app-server-fuse63</artifactId>
744
                    <version>${project.version}</version>
745
                    <scope>runtime</scope>
746
                </dependency>
747
                <dependency>
748
                    <groupId>org.keycloak.testsuite</groupId>
749
                    <artifactId>integration-arquillian-test-apps-fuse-parent</artifactId>
750
                    <version>${project.version}</version>
751
                    <scope>runtime</scope>
752
                    <type>pom</type>
753
                </dependency>
754
                <dependency>
755
                    <groupId>org.jboss.arquillian.container</groupId>
756
                    <artifactId>arquillian-container-karaf-managed</artifactId>
757
                </dependency>
758
            </dependencies>
759
            <build>
760
                <plugins>
761
                    <plugin>
762
                        <artifactId>maven-enforcer-plugin</artifactId>
763
                        <goals>
764
                            <goal>enforce</goal>
765
                        </goals>
766
                        <configuration>
767
                            <rules>
768
                                <requireProperty>
769
                                    <message>When running fuse tests 'additional.fuse.repos' is expected to be set.</message>
770
                                    <property>additional.fuse.repos</property>
771
                                </requireProperty>
772
                                <requireProperty>
773
                                    <message>When running fuse tests 'fuse.adapter.version' is expected to be set.</message>
774
                                    <property>fuse.adapter.version</property>
775
                                </requireProperty>
776
                            </rules>
777
                        </configuration>
778
                    </plugin>
779
                    <plugin>
780
                        <groupId>org.commonjava.maven.plugins</groupId>
781
                        <artifactId>directory-maven-plugin</artifactId>
782
                    </plugin>
783
                    <plugin>
784
                        <artifactId>maven-surefire-plugin</artifactId>
785
                        <configuration>
786
                            <systemPropertyVariables>
787
                                <app.server.management.user>${app.server.management.user}</app.server.management.user>
788
                                <app.server.management.password>${app.server.management.password}</app.server.management.password>
789
                                <app.server.karaf.jvm.debug.args>${app.server.karaf.jvm.debug.args}</app.server.karaf.jvm.debug.args>
790
                            </systemPropertyVariables>
791
                        </configuration>
792
                    </plugin>
793
                </plugins>
794
            </build>
795
        </profile>
796
        <profile>
797
            <id>app-server-fuse7x</id>
798
            <activation>
799
                <property>
800
                    <name>app.server</name>
801
                    <value>fuse7x</value>
802
                </property>
803
            </activation>
804
            <properties>
805
                <app.server>fuse7x</app.server> <!--in case the profile is called directly-->
806
                <app.server.skip.unpack>false</app.server.skip.unpack>
807

808
                <!--fuse examples expect auth server on 8080-->
809
                <auth.server.port.offset>0</auth.server.port.offset>
810
                <auth.server.http.port>8080</auth.server.http.port>
811
                <auth.server.management.port>9990</auth.server.management.port>
812
                <!--fuse examples expect default karaf http port 8181-->
813
                <app.server.http.port>8181</app.server.http.port>
814

815
                <app.server.management.user>admin</app.server.management.user>
816
                <app.server.management.password>password</app.server.management.password>
817
                <app.server.karaf.jvm.debug.args>-agentlib:jdwp=transport=dt_socket,server=y,suspend=${app.server.debug.suspend},address=localhost:${app.server.debug.port}</app.server.karaf.jvm.debug.args>
818
            </properties>
819
            <dependencies>
820
                <dependency>
821
                    <groupId>org.keycloak.testsuite</groupId>
822
                    <artifactId>integration-arquillian-servers-app-server-fuse7x</artifactId>
823
                    <version>${project.version}</version>
824
                    <scope>runtime</scope>
825
                </dependency>
826
                <dependency>
827
                    <groupId>org.keycloak.testsuite</groupId>
828
                    <artifactId>integration-arquillian-test-apps-fuse-parent</artifactId>
829
                    <version>${project.version}</version>
830
                    <scope>runtime</scope>
831
                    <type>pom</type>
832
                </dependency>
833
                <dependency>
834
                    <groupId>org.jboss.arquillian.container</groupId>
835
                    <artifactId>arquillian-container-karaf-managed</artifactId>
836
                </dependency>
837
            </dependencies>
838
            <build>
839
                <plugins>
840
                    <plugin>
841
                        <artifactId>maven-enforcer-plugin</artifactId>
842
                        <goals>
843
                            <goal>enforce</goal>
844
                        </goals>
845
                        <configuration>
846
                            <rules>
847
                                <requireProperty>
848
                                    <message>When running fuse tests 'additional.fuse.repos' is expected to be set.</message>
849
                                    <property>additional.fuse.repos</property>
850
                                </requireProperty>
851
                            </rules>
852
                        </configuration>
853
                    </plugin>
854
                    <plugin>
855
                        <groupId>org.commonjava.maven.plugins</groupId>
856
                        <artifactId>directory-maven-plugin</artifactId>
857
                    </plugin>
858
                    <plugin>
859
                        <artifactId>maven-surefire-plugin</artifactId>
860
                        <configuration>
861
                            <systemPropertyVariables>
862
                                <app.server.management.user>${app.server.management.user}</app.server.management.user>
863
                                <app.server.management.password>${app.server.management.password}</app.server.management.password>
864
                                <app.server.karaf.jvm.debug.args>${app.server.karaf.jvm.debug.args}</app.server.karaf.jvm.debug.args>
865
                            </systemPropertyVariables>
866
                        </configuration>
867
                    </plugin>
868
                </plugins>
869
            </build>
870
        </profile>
871
        <!-- EAP6, Fuse 6.x and Fuse 7.x adapter profiles END -->
872

873
        <profile>
874
            <id>app-server-tomcat8</id>
875
            <activation>
876
                <property>
877
                    <name>app.server</name>
878
                    <value>tomcat8</value>
879
                </property>
880
            </activation>
881
            <properties>
882
                <app.server>tomcat8</app.server> <!--in case the profile is called directly-->
883
                <app.server.skip.unpack>false</app.server.skip.unpack>
884
                <app.server.artifactId>integration-arquillian-servers-app-server-tomcat8</app.server.artifactId><!-- Need to override -->
885
                <app.server.port.offset>0</app.server.port.offset>
886
                <app.server.http.port>8080</app.server.http.port>
887
                <app.server.management.port>9990</app.server.management.port>
888
                <app.server.keystore.dir>${app.server.home}/lib</app.server.keystore.dir>
889
            </properties>
890
            <dependencies>
891
                <dependency>
892
                    <groupId>org.keycloak.testsuite</groupId>
893
                    <artifactId>integration-arquillian-servers-app-server-tomcat8</artifactId>
894
                    <version>${project.version}</version>
895
                    <scope>runtime</scope>
896
                </dependency>
897
            </dependencies>
898
            <build>
899
                <plugins>
900
                    <plugin>
901
                        <groupId>org.commonjava.maven.plugins</groupId>
902
                        <artifactId>directory-maven-plugin</artifactId>
903
                    </plugin>
904
                </plugins>
905
            </build>
906
        </profile>
907
        <profile>
908
            <id>app-server-tomcat9</id>
909
            <activation>
910
                <property>
911
                    <name>app.server</name>
912
                    <value>tomcat9</value>
913
                </property>
914
            </activation>
915
            <properties>
916
                <app.server>tomcat9</app.server> <!--in case the profile is called directly-->
917
                <app.server.skip.unpack>false</app.server.skip.unpack>
918
                <app.server.artifactId>integration-arquillian-servers-app-server-tomcat9</app.server.artifactId><!-- Need to override -->
919
                <app.server.port.offset>0</app.server.port.offset>
920
                <app.server.http.port>8080</app.server.http.port>
921
                <app.server.management.port>9990</app.server.management.port>
922
                <app.server.keystore.dir>${app.server.home}/lib</app.server.keystore.dir>
923
            </properties>
924
            <dependencies>
925
                <dependency>
926
                    <groupId>org.keycloak.testsuite</groupId>
927
                    <artifactId>integration-arquillian-servers-app-server-tomcat9</artifactId>
928
                    <version>${project.version}</version>
929
                    <scope>runtime</scope>
930
                </dependency>
931
            </dependencies>
932
            <build>
933
                <plugins>
934
                    <plugin>
935
                        <groupId>org.commonjava.maven.plugins</groupId>
936
                        <artifactId>directory-maven-plugin</artifactId>
937
                    </plugin>
938
                </plugins>
939
            </build>
940
        </profile>
941
        <profile>
942
            <id>auth-servers-crossdc-undertow</id>
943
            <properties>
944
                <skip.clean.second.cache>false</skip.clean.second.cache>
945
                <exclude.crossdc>-</exclude.crossdc>
946
                <surefire.memory.Xmx>1024m</surefire.memory.Xmx>
947
            </properties>
948
        </profile>
949
        <profile>
950
            <id>auth-servers-crossdc-jboss</id>
951
            <properties>
952
                <skip.clean.second.cache>false</skip.clean.second.cache>
953
                <skip.copy.auth.crossdc.nodes>false</skip.copy.auth.crossdc.nodes>
954
                <exclude.crossdc>-</exclude.crossdc>
955
                <surefire.memory.Xmx>1024m</surefire.memory.Xmx>
956
            </properties>
957
        </profile>
958

959
        <profile>
960
            <id>generate-certs-for-custom-app-server-host</id>
961
            <activation>
962
                <property>
963
                    <name>app.server.host</name>
964
                </property>
965
            </activation>
966
            <build>
967
                <pluginManagement>
968
                    <plugins>
969
                        <plugin>
970
                            <groupId>org.codehaus.mojo</groupId>
971
                            <artifactId>keytool-maven-plugin</artifactId>
972
                            <executions>
973
                                <execution>
974
                                    <id>remove-old-app-server-key</id>
975
                                    <phase>generate-test-resources</phase>
976
                                    <goals>
977
                                        <goal>deleteAlias</goal>
978
                                    </goals>
979
                                    <configuration>
980
                                        <keystore>${app.server.keystore}</keystore>
981
                                        <storepass>${app.server.keystore.password}</storepass>
982
                                        <alias>localhost3</alias>
983
                                        <skip>${app.server.skip.unpack}</skip>
984
                                    </configuration>
985
                                </execution>
986
                                <execution>
987
                                    <id>generate-new-app-server-cert</id>
988
                                    <phase>generate-test-resources</phase>
989
                                    <goals>
990
                                        <goal>generateKeyPair</goal>
991
                                    </goals>
992
                                    <configuration>
993
                                        <keystore>${app.server.keystore}</keystore>
994
                                        <storepass>${app.server.keystore.password}</storepass>
995
                                        <alias>${app.server.host}</alias>
996
                                        <dname>CN=${app.server.host}, OU=Keycloak, O=Red Hat, L=Westword, ST=MA, C=US</dname>
997
                                        <keyalg>RSA</keyalg>
998
                                        <keysize>2048</keysize>
999
                                        <sigalg>SHA256withRSA</sigalg>
1000
                                    </configuration>
1001
                                </execution>
1002
                                <execution>
1003
                                    <id>export-app-server-cert</id>
1004
                                    <phase>generate-test-resources</phase>
1005
                                    <goals>
1006
                                        <goal>exportCertificate</goal>
1007
                                    </goals>
1008
                                    <configuration>
1009
                                        <keystore>${app.server.keystore}</keystore>
1010
                                        <storepass>${app.server.keystore.password}</storepass>
1011
                                        <alias>${app.server.host}</alias>
1012
                                        <file>${dependency.keystore.root}/${app.server.host}.pem</file>
1013
                                    </configuration>
1014
                                </execution>
1015
                                <execution>
1016
                                    <id>import-app-server-cert-to-truststore</id>
1017
                                    <phase>generate-test-resources</phase>
1018
                                    <goals>
1019
                                        <goal>importCertificate</goal>
1020
                                    </goals>
1021
                                    <configuration>
1022
                                        <keystore>${dependency.truststore}</keystore>
1023
                                        <storepass>${dependency.truststore.password}</storepass>
1024
                                        <alias>${app.server.host}</alias>
1025
                                        <file>${dependency.keystore.root}/${app.server.host}.pem</file>
1026
                                        <trustcacerts>true</trustcacerts>
1027
                                        <noprompt>true</noprompt>
1028
                                    </configuration>
1029
                                </execution>
1030
                            </executions>
1031
                        </plugin>
1032
                        <plugin>
1033
                            <artifactId>maven-resources-plugin</artifactId>
1034
                            <executions>
1035
                                <execution>
1036
                                    <id>copy-processed-truststore-to-app-server</id>
1037
                                    <phase>process-test-resources</phase>
1038
                                    <goals>
1039
                                        <goal>copy-resources</goal>
1040
                                    </goals>
1041
                                    <configuration>
1042
                                        <outputDirectory>${app.server.keystore.dir}</outputDirectory>
1043
                                        <resources>
1044
                                            <resource>
1045
                                                <directory>${dependency.keystore.root}</directory>
1046
                                            </resource>
1047
                                        </resources>
1048
                                        <overwrite>true</overwrite>
1049
                                        <skip>${app.server.skip.unpack}</skip>
1050
                                    </configuration>
1051
                                </execution>
1052
                                <execution>
1053
                                    <id>copy-processed-truststore-to-secured-deployment-app-server-config</id>
1054
                                    <phase>process-test-resources</phase>
1055
                                    <goals>
1056
                                        <goal>copy-resources</goal>
1057
                                    </goals>
1058
                                    <configuration>
1059
                                        <outputDirectory>${app.server.home}/standalone-secured-deployments/configuration</outputDirectory>
1060
                                        <resources>
1061
                                            <resource>
1062
                                                <directory>${dependency.keystore.root}</directory>
1063
                                            </resource>
1064
                                        </resources>
1065
                                        <overwrite>true</overwrite>
1066
                                        <skip>${app.server.skip.unpack}</skip>
1067
                                    </configuration>
1068
                                </execution>
1069
                                <execution>
1070
                                    <id>copy-processed-keystore-to-secured-deployment-app-server-config</id>
1071
                                    <phase>process-test-resources</phase>
1072
                                    <goals>
1073
                                        <goal>copy-resources</goal>
1074
                                    </goals>
1075
                                    <configuration>
1076
                                        <outputDirectory>${app.server.home}/standalone-secured-deployments/configuration</outputDirectory>
1077
                                        <resources>
1078
                                            <resource>
1079
                                                <directory>${app.server.keystore.dir}</directory>
1080
                                                <includes>
1081
                                                    <include>adapter.jks</include>
1082
                                                </includes>
1083
                                            </resource>
1084
                                        </resources>
1085
                                        <overwrite>true</overwrite>
1086
                                        <skip>${app.server.skip.unpack}</skip>
1087
                                    </configuration>
1088
                                </execution>
1089
                            </executions>
1090
                        </plugin>
1091
                    </plugins>
1092
                </pluginManagement>
1093
            </build>
1094
        </profile>
1095

1096
        <profile>
1097
            <id>auth-server-fips140-2</id>
1098

1099
            <build>
1100
                <plugins>
1101
                    <plugin>
1102
                        <artifactId>maven-resources-plugin</artifactId>
1103
                        <executions>
1104
                            <execution>
1105
                                <id>copy-bcfips-deps-client-tools</id>
1106
                                <phase>process-test-resources</phase>
1107
                                <goals>
1108
                                    <goal>copy-resources</goal>
1109
                                </goals>
1110
                                <configuration>
1111
                                    <outputDirectory>${containers.home}/keycloak-client-tools/bin/client/lib</outputDirectory>
1112
                                    <resources>
1113
                                        <resource>
1114
                                            <directory>${containers.home}/auth-server-quarkus/bin/client/lib</directory>
1115
                                            <includes>
1116
                                                <include>bc-fips-*</include>
1117
                                                <include>bctls-fips-*</include>
1118
                                            </includes>
1119
                                        </resource>
1120
                                    </resources>
1121
                                </configuration>
1122
                            </execution>
1123
                        </executions>
1124
                    </plugin>
1125
                </plugins>
1126
            </build>
1127
        </profile>
1128

1129
        <profile>
1130
            <id>auth-server-quarkus-embedded</id>
1131
            <properties>
1132
                <surefire.memory.Xms>2048m</surefire.memory.Xms>
1133
                <surefire.memory.Xmx>2048m</surefire.memory.Xmx>
1134
                <surefire.memory.metaspace>512m</surefire.memory.metaspace>
1135
                <surefire.memory.metaspace.max>1024m</surefire.memory.metaspace.max>
1136
                <junit-vintage-engine.version>5.9.3</junit-vintage-engine.version>
1137
            </properties>
1138
            <dependencies>
1139
                <dependency>
1140
                    <groupId>org.keycloak</groupId>
1141
                    <artifactId>keycloak-junit5</artifactId>
1142
                    <version>${project.version}</version>
1143
                    <exclusions>
1144
                        <!-- TODO: FIPS not yet supported -->
1145
                        <exclusion>
1146
                            <groupId>org.keycloak</groupId>
1147
                            <artifactId>keycloak-crypto-fips1402</artifactId>
1148
                        </exclusion>
1149
                    </exclusions>
1150
                </dependency>
1151
                <dependency>
1152
                    <groupId>org.junit.vintage</groupId>
1153
                    <artifactId>junit-vintage-engine</artifactId>
1154
                    <version>${junit-vintage-engine.version}</version>
1155
                    <scope>test</scope>
1156
                </dependency>
1157
                <dependency>
1158
                    <groupId>org.jboss.logmanager</groupId>
1159
                    <artifactId>log4j-jboss-logmanager</artifactId>
1160
                    <version>1.3.0.Final</version>
1161
                </dependency>
1162
                <dependency>
1163
                    <groupId>net.bytebuddy</groupId>
1164
                    <artifactId>byte-buddy</artifactId>
1165
                    <version>1.12.18</version>
1166
                </dependency>
1167
            </dependencies>
1168
        </profile>
1169

1170
    </profiles>
1171

1172
</project>
1173

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.