Hi Keycloak developers,
On one of our build infrastructures, we build Keycloak with the following mvn command:
mvn -nsu -Pauth-server-wildfly -Pdistribution -DskipTests -Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn clean install
Since Keycloak 14 was released, our build fails with the following error:
Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:3.1.2:unpack (unpack-and-inject-keycloak-server-feature-pack-licenses) on project keycloak-server-dist: Unable to find/resolve artifact.: Could not find artifact org.keycloak:keycloak-server-feature-pack:zip:15.0.0-SNAPSHOT in jboss-public-repository-group (https://repository.jboss.org/nexus/content/groups/public/) -> [Help 1]
This error occurs when the corresponding dependency does not already exist in the local maven repository, before the build is started.
I was able to fix this by adding the following dependency to distribution/server-dist/pom.xml:
<dependency>
<groupId>org.keycloak</groupId>
<artifactId>keycloak-server-feature-pack</artifactId>
<type>zip</type>
<scope>provided</scope>
</dependency>
This makes sure that the module keycloak-server-feature-pack is built before keycloak-server-dist.
Interestingly, the issue does not occur when we omit the auth-server-wildfly profile – because the Maven Build Order is different in this case, keycloak-server-feature-pack is then built before keycloak-server-dist.
Does anyone else have similar issues?
Our build has been inspired by the travis scripts provided in the Keycloak repo. Probably we should better switch to Github Actions? (With Github Actions, the issue does not occur, as we observed on one of our Keycloak forks on Github.)
Nevertheless, the missing dependency declaration is a bug imo, and I would like to provide a corresponding PR.
I am happy about your feedback.
Mit freundlichen Grüßen / Best regards
Daniel Fesenmeyer
Bosch IoT Permissions - Product Area User Management (IOC/PAU-PM)
Bosch.IO GmbH | Ziegelei 7 | 88090 Immenstaad |
GERMANY | www.bosch.io
Tel. +49 7545 202-360 | Telefax +49 7545 202-301 | Daniel.F...@bosch.io
Sitz: Berlin, Registergericht: Amtsgericht Charlottenburg; HRB 148411 B
Aufsichtsratsvorsitzender: Dr.-Ing. Thorsten Lücke; Geschäftsführung: Dr. Stefan Ferber, Dr. Aleksandar Mitrovic, Yvonne Reckling
Hi Andrew,
Thanks for the link and the explanation how you build Keycloak.
Sadly, we cannot use your setup because we have a build similar to the Keycloak travis build, which specifies the profiles “auth-server-wildfly” and “distribution” (which are not included in your example, but these are the ones which cause the build to fail).
As a workaround, we switched to Github Actions, which works fine so far.
Mit freundlichen Grüßen / Best regards
Daniel Fesenmeyer
Bosch IoT Permissions - Product Area User Management (IOC/PAU-PM)
Bosch.IO GmbH | Ziegelei 7 | 88090 Immenstaad |
GERMANY | www.bosch.io
Tel. +49 7545 202-360 | Telefax +49 7545 202-301 | Daniel.F...@bosch.io
Sitz: Berlin, Registergericht: Amtsgericht Charlottenburg; HRB 148411 B
Aufsichtsratsvorsitzender: Dr.-Ing. Thorsten Lücke; Geschäftsführung: Dr. Stefan Ferber, Dr. Aleksandar Mitrovic, Yvonne Reckling
--
You received this message because you are subscribed to the Google Groups "Keycloak Dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
keycloak-dev...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/keycloak-dev/d683d54e-d3bf-4c64-b2dd-1acefb616795n%40googlegroups.com.