Missing site information in the distribution management of the project spring-swagger-wordnik-client - maven

I am trying to create a Maven repository for a project of mine.
The relevant lines in my project's pom.xml file are:
<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>edu.mills.cs180a</groupId>
<artifactId>spring-swagger-wordnik-client</artifactId>
<packaging>jar</packaging>
<name>spring-swagger-wordnik-client</name>
<version>0.0.2A-SNAPSHOT</version>
...
<distributionManagement>
<repository>
<id>CS180A site</id>
<url>file:///C:/Users/ellen/Dropbox/Apps/site44/www.spertus.com/cs180a</url>
</repository>
</distributionManagement>
...
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<version>3.7.1</version>
</plugin>
...
</plugins>
</project>
I get this error when I try to deploy the site:
$ mvn site:deploy
[INFO] Scanning for projects...
[INFO]
[INFO] -----------< edu.mills.cs180a:spring-swagger-wordnik-client >-----------
[INFO] Building spring-swagger-wordnik-client 0.0.2A-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] --- maven-site-plugin:3.7.1:deploy (default-cli) # spring-swagger-wordnik-client ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.055 s
[INFO] Finished at: 2020-11-11T15:24:38-08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-site-plugin:3.7.1:deploy (default-cli) on project spring-swagger-wordnik-client: Missing site information in the distribution management of the project spring-swagger-wordnik-client (edu.mills.cs180a:spring-swagger-wordnik-client:0.0.2A-SNAPSHOT) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
I don't understand why I get this error:
Missing site information in the distribution management of the project spring-swagger-wordnik-client
What else should be in distribution management besides this?
<distributionManagement>
<repository>
<id>CS180A site</id>
<url>file:///C:/Users/ellen/Dropbox/Apps/site44/www.spertus.com/cs180a</url>
</repository>
</distributionManagement>

Looking at your configuration, you need to add element inside distributionManagement as explained here: https://maven.apache.org/plugins/maven-site-plugin/usage.html.

Related

Publish additional external jar-files to ossrh with maven

I want to publish my projects artifacts with maven to nexus. Therefore I followed this documentation which works for me for artifacts which are also build with maven. But now I want to publish additional artifacts (*.tgz files) which I download from somewhere else. I have not yet found out how to express in maven terms that I want to deploy those "local" artifacts.
What I tried is:
Create a new staging repo on ossrh with the pom file. This works and a new, open staging repository is created containing the pom file and a signature file.
> mvn deploy -DrepositoryId=ossrh
upload additional resources. This fails
> mvn deploy:deploy-file -Dfile=test-tst-0.0.1_linux-ppc64le_bin.tar.gz -Dclassifier=linux-ppc64le -DrepositoryId=ossrh -Durl=https://s01.oss.sonatype.org/content/repositories/iosapmachine-1031 -DgroupId=io.sapmachine -DartifactId=test-tst -Dversion=0.0.1
[INFO] Scanning for projects...
[INFO]
[INFO] -----------------------< io.sapmachine:test-tst >-----------------------
[INFO] Building io.sapmachine:test-tst 0.0.1
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] --- maven-deploy-plugin:2.7:deploy-file (default-cli) # test-tst ---
Uploading to ossrh: https://s01.oss.sonatype.org/content/repositories/iosapmachine-1031/io/sapmachine/test-tst/0.0.1/test-tst-0.0.1-linux-ppc64le.gz
Uploading to ossrh: https://s01.oss.sonatype.org/content/repositories/iosapmachine-1031/io/sapmachine/test-tst/0.0.1/test-tst-0.0.1.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.002 s
[INFO] Finished at: 2021-12-08T09:02:40+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy-file (default-cli) on project test-tst: Failed to deploy artifacts: Could not find artifact io.sapmachine:test-tst:gz:linux-ppc64le:0.0.1 in ossrh (https://s01.oss.sonatype.org/content/repositories/iosapmachine-1031) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
My pom.xml looks like this:
> cat pom.xml
<?xml version="1.0" encoding="utf-8"?>
<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">
<groupId>io.sapmachine</groupId>
<artifactId>test-tst</artifactId>
<version>0.0.1</version>
<name>${project.groupId}:${project.artifactId}</name>
<description>Test</description>
<packaging>pom</packaging>
<modelVersion>4.0.0</modelVersion>
<url>https://test.io/</url>
<licenses>
<license>
<name>GPLv2 + Classpath Exception</name>
<url>https://test/LICENSE</url>
</license>
</licenses>
<distributionManagement>
<snapshotRepository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2</url>
</repository>
</distributionManagement>
<developers>
<developer>
<name>Test</name>
<email>test#test.com</email>
<organization>Test AG</organization>
<organizationUrl>http://www.test.com</organizationUrl>
</developer>
</developers>
<scm>
<connection>scm:git:https://github.com/test/tree/test-${project.version}</connection>
<url>http://github.com/test/tree/test-${project.version}</url>
</scm>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>3.0.1</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
>

Failed to execute goal org.openjfx:javafx-maven-plugin:0.0.6:run (default-cli) on project : Error: Error: Output directory is empty -> [Help 1]

I have a non-modular javafx project and want to run it with maven but i have no experience in it.
I'm using IntelliJ IDEA so I went to root directory, right click -> Add Framework Support, and choose maven. a pom.xml file was added.
After referring https://openjfx.io/openjfx-docs/#maven I modified The pom.xml file to look like this:
<?xml version="1.0" encoding="UTF-8"?>
<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.openjfx</groupId>
<artifactId>AccountZeyny</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>
<name>AccountZeyny</name>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.release>11</maven.compiler.release>
<javafx.version>15</javafx.version>
<javafx.maven.plugin.version>0.0.6</javafx.maven.plugin.version>
</properties>
<organization>
<!-- Used as the 'Vendor' for JNLP generation -->
<name>ORGZ</name>
</organization>
<dependencies>
<dependency>
<groupId>org.openjfx</groupId>
<artifactId>javafx-controls</artifactId>
<version>15</version>
</dependency>
<dependency>
<groupId>org.openjfx</groupId>
<artifactId>javafx-fxml</artifactId>
<version>15</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<configuration>
<release>${maven.compiler.release}</release>
</configuration>
</plugin>
<plugin>
<groupId>org.openjfx</groupId>
<artifactId>javafx-maven-plugin</artifactId>
<version>0.0.6</version>
<configuration>
<release>${maven.compiler.release}</release>
<mainClass>org.openjfx.Main</mainClass>
</configuration>
</plugin>
</plugins>
</build>
</project>
I went to Maven tab -> Plugins -> compiler -> compiler:compile. and then Plugins -> javafx -> javafx:run. and I got this in the run tab down below:
D:\openjdk-15.0.1_windows-x64_bin\jdk-15.0.1\bin\java.exe -Dmaven.multiModuleProjectDirectory=D:\Account-Zeyny "-Dmaven.home=D:\IntelliJ IDEA Community Edition 2021.1.3\plugins\maven\lib\maven3" "-Dclassworlds.conf=D:\IntelliJ IDEA Community Edition 2021.1.3\plugins\maven\lib\maven3\bin\m2.conf" "-Dmaven.ext.class.path=D:\IntelliJ IDEA Community Edition 2021.1.3\plugins\maven\lib\maven-event-listener.jar" "-javaagent:D:\IntelliJ IDEA Community Edition 2021.1.3\lib\idea_rt.jar=64148:D:\IntelliJ IDEA Community Edition 2021.1.3\bin" -Dfile.encoding=UTF-8 -classpath "D:\IntelliJ IDEA Community Edition 2021.1.3\plugins\maven\lib\maven3\boot\plexus-classworlds-2.6.0.jar;D:\IntelliJ IDEA Community Edition 2021.1.3\plugins\maven\lib\maven3\boot\plexus-classworlds.license" org.codehaus.classworlds.Launcher -Didea.version=2021.1.3 org.openjfx:javafx-maven-plugin:0.0.6:run
[INFO] Scanning for projects...
[INFO]
[INFO] ----------------------< org.openjfx:AccountZeyny >----------------------
[INFO] Building AccountZeyny 1.0-SNAPSHOT
[INFO] --------------------------------[ jar ]---------------------------------
[INFO]
[INFO] >>> javafx-maven-plugin:0.0.6:run (default-cli) > process-classes # AccountZeyny >>>
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) # AccountZeyny ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] skip non existing resourceDirectory D:\Account-Zeyny\src\main\resources
[INFO]
[INFO] --- maven-compiler-plugin:3.8.1:compile (default-compile) # AccountZeyny ---
[INFO] No sources to compile
[INFO]
[INFO] <<< javafx-maven-plugin:0.0.6:run (default-cli) < process-classes # AccountZeyny <<<
[INFO]
[INFO]
[INFO] --- javafx-maven-plugin:0.0.6:run (default-cli) # AccountZeyny ---
[INFO] Toolchain in javafx-maven-plugin null
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 25.189 s
[INFO] Finished at: 2021-07-15T18:02:32+03:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.openjfx:javafx-maven-plugin:0.0.6:run (default-cli) on project AccountZeyny: Error: Error: Output directory is empty -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
Process finished with exit code 1
Did I make mistake in these steps?
EDIT: I'm using IntelliJ IDEA 2021.1.3 x64.

The desired archetype does not exist

When calling Maven to generate an archetype following the instructions at https://confluence.sakaiproject.org/display/BOOT/Sakai+Spring+MVC+Maven+Archetype, Maven complains about the archetype being inexistent, even though the file is located in the given archetype respository: https://source.sakaiproject.org/maven2/org/sakaiproject/maven-archetype/sakai-spring-maven-archetype/1.2/sakai-spring-maven-archetype-1.2.pom.
Maven version is:
>mvn -version
Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
This is what happens - it looks like the -DarchetypeRepository parameter is ignored:
> mvn archetype:generate -DarchetypeGroupId=org.sakaiproject.maven-archetype
-DarchetypeArtifactId=sakai-spring-maven-archetype
-DarchetypeVersion=1.2
-DarchetypeRepository=https://source.sakaiproject.org/maven2
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------< org.apache.maven:standalone-pom >-------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] --------------------------------[ pom ]---------------------------------
[INFO]
[INFO] >>> maven-archetype-plugin:3.1.2:generate (default-cli) > generate-sources # standalone-pom >>>
[INFO]
[INFO] <<< maven-archetype-plugin:3.1.2:generate (default-cli) < generate-sources # standalone-pom <<<
[INFO]
[INFO]
[INFO] --- maven-archetype-plugin:3.1.2:generate (default-cli) # standalone-pom ---
[INFO] Generating project in Interactive mode
[WARNING] Archetype not found in any catalog. Falling back to central repository.
[WARNING] Add a repository with id 'archetype' in your settings.xml if archetype's repository is elsewhere.
[WARNING] The POM for org.sakaiproject.maven-archetype:sakai-spring-maven-archetype:jar:1.2 is missing, no dependency information available
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.395 s
[INFO] Finished at: 2020-01-11T12:24:20+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-archetype-plugin:3.1.2:generate (default-cli) on project standalone-pom: The desired archetype does not exist (org.sakaiproject.maven-archetype:sakai-spring-maven-archetype:1.2) -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
Turns out that Maven 3 changed the way archetype repositories are integrated. The -DarchetypeRepository parameter is not there anymore. Instead, archteype repositories need to be added to settings.xml:
<profiles>
<profile>
<!-- the profile id is arbitrary -->
<id>sakai</id>
<repositories>
<repository>
<!-- the repository id has to be named: archetype -->
<id>archetype</id>
<name>Repository for Sakai archetypes</name>
<url>https://source.sakaiproject.org/maven2/</url>
<releases>
<enabled>true</enabled>
<checksumPolicy>fail</checksumPolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<checksumPolicy>warn</checksumPolicy>
</snapshots>
</repository>
</repositories>
</profile>
</profiles>
<!-- The profile needs to be added to activeProfiles in order to be taken into account -->
<activeProfiles>
<activeProfile>sakai</activeProfile>
</activeProfiles>

Dart-Maven-Plugin execute pub get only

I am trying to write a maven pom file that only runs pub get. However when I run mvn clean package, I get errors saying there is no main.dart file. My dart project contains reusable dart classes that I just want packaged up to be imported elsewhere, so there is no main.dart file. When I run pub get from the command line in that directory the packages are created. Here is my pom.xml file.
<?xml version="1.0" encoding="UTF-8"?>
<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>com.abc.comp</groupId>
<artifactId>a_comp</artifactId>
<name>a_comp</name>
<build>
<plugins>
<plugin>
<groupId>com.github.dzwicker.dart</groupId>
<artifactId>dart-maven-plugin</artifactId>
<version>3.0.8</version>
<configuration>
<pubCommand>get</pubCommand>
</configuration>
<executions>
<execution>
<id>pub-get</id>
<phase>compile</phase>
<goals>
<goal>pub</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<packaging>pom</packaging>
<version>0.0.1-SNAPSHOT</version>
</project>
Is this trying to run something other than just "pub get"? Any suggestions would be appreciated!
Edit:
Here is the maven log when I run mvn clean package. I've also tried adding a src/main/dart
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building a_comp 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) # a_comp ---
[INFO]
[INFO] --- dart-maven-plugin:3.0.8:pub (pub-get) # a_comp ---
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.359 s
[INFO] Finished at: 2015-11-30T12:55:53-08:00
[INFO] Final Memory: 7M/234M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal com.github.dzwicker.dart:dart-maven-plugin:3.0.8:pub (pub-get) on project a_comp
: Compiler-source-root 'C:\Users\s\Git Projects\project\a_comp\src\main\dart' does not exist. -> [Help 1
]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

Maven build not finding custom jar already installed in local openshift project repo

I am facing an issue when trying to build my project (from the Eclipse Openshift plugin).
1.) I have a custom dependency, which at first I followed instructions on Open Shift Knowledgebase Article "Using your own jar files..."
2.) On commit and publish with above, the error still persisted, thereby I changed the openshift pre_build action hook as noted in this post on the Openshift forums "Resolved custom jar dependency..."
However, I am still getting an error on commit and publish from eclipse. Here's a dump from the console
Repository ssh://53211e7...50000f0#testapp0...312-systix.rhcloud.com/~/git/testapp0...312.git/
Stopping RockMongo cartridge
[Sun Mar 16 12:20:37 2014] [warn] module php5_module is already loaded, skipping
httpd (no pid file) not running
MongoDB already stopped
Stopping jbossas cartridge
Repairing links for 1 deployments
Building git ref 'master', commit bb2def3
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.3.1:install-file (default-cli) # standalone-pom ---
[INFO] Installing /var/lib/openshift/app-root/runtime/repo/shared-helper-data-skychart-0.0.1-SNAPSHOT.jar to /var/lib/openshift/53211e...0f0/.m2/repository/com/systix/shared-helper-data-skychart/0.0.1-SNAPSHOT/shared-helper-data-skychart-0.0.1-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.331s
[INFO] Finished at: Sun Mar 16 12:20:48 EDT 2014
[INFO] Final Memory: 4M/78M
[INFO] ------------------------------------------------------------------------
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Maven Stub Project (No POM) 1
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-install-plugin:2.3.1:install-file (default-cli) # standalone-pom ---
[INFO] Installing /var/lib/openshift/app-root/runtime/repo/shared-models-skychart-0.0.1-SNAPSHOT.jar to /var/lib/openshift/5321......00f0/.m2/repository/com/systix/shared-models-skychart/0.0.1-SNAPSHOT/shared-models-skychart-0.0.1-SNAPSHOT.jar
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.723s
[INFO] Finished at: Sun Mar 16 12:20:53 EDT 2014
[INFO] Final Memory: 4M/78M
[INFO] ------------------------------------------------------------------------
Found pom.xml... attempting to build with 'mvn -e clean package -Popenshift -DskipTests'
Apache Maven 3.0.3 (r1075437; 2011-06-20 13:22:37-0400)
Maven home: /etc/alternatives/maven-3.0
Java version: 1.7.0_51, vendor: Oracle Corporation
Java home: /usr/lib/jvm/java-1.7.0-openjdk-1.7.0.51/jre
Default locale: en_US, platform encoding: ANSI_X3.4-1968
OS name: "linux", version: "2.6.32-431.5.1.el6oso.bz844450.x86_64", arch: "i386", family: "unix"
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building testapp0...312 1.0
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.134s
[INFO] Finished at: Sun Mar 16 12:21:04 EDT 2014
[INFO] Final Memory: 5M/111M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project testapp0...0312: Could not resolve dependencies for project testapp0...0312:testapp0...312:war:1.0: Could not find artifact com.systix:shared-helper-data-skychart:jar:0.0.1-SNAPSHOT -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
An error occurred executing 'gear postreceive' (exit code: 1)
Error message: CLIENT_ERROR: Failed to execute: 'control build' for /var/lib/openshift/5321...00f0/jbossas
For more details about the problem, try running the command again with the '--trace' option.
On reviewing the above it seems like maven is able to add the dependency jars succesfully to the local repo ,but the build for the project does not seem to.
UPDATE: Including the pom.xml from both the libraries that I have marked as to be installed in the pre_build file. Both the jars were built, included in the openshift git repo, and referenced in the pre_build script to be installed in openshift's maven repo (pre_build script included at end)
pom.xml from shared-helper-data-skychart:
<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>com.systix</groupId>
<artifactId>shared-helper-data-skychart</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<build>
<sourceDirectory>src</sourceDirectory>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.mongodb</groupId>
<artifactId>mongo-java-driver</artifactId>
<version>2.11.4</version>
</dependency>
<dependency>
<groupId>com.systix</groupId>
<artifactId>shared-models-skychart</artifactId>
<version>0.0.1-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.mongodb.morphia</groupId>
<artifactId>morphia</artifactId>
<version>0.105</version>
</dependency>
</dependencies>
</project>
pom.xml from shared-models-skychart (shared-models-skychart is a dependency in the pom.xml for shared-helper-data-skychart)
<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>com.systix</groupId>
<artifactId>shared-models-skychart</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<build>
<sourceDirectory>src</sourceDirectory>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<source>1.7</source>
<target>1.7</target>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.mongodb.morphia</groupId>
<artifactId>morphia</artifactId>
<version>0.105</version>
</dependency>
<dependency>
<groupId>org.jsoup</groupId>
<artifactId>jsoup</artifactId>
<version>1.7.3</version>
</dependency>
<dependency>
<groupId>org.mongodb</groupId>
<artifactId>mongo-java-driver</artifactId>
<version>2.11.4</version>
</dependency>
</dependencies>
</project>
pre_build script used
mvn install:install-file -Dfile=../app-root/runtime/repo/shared-helper-data-skychart-0.0.1-SNAPSHOT.jar -DgroupId=com.systix -DartifactId=shared-helper-data-skychart -Dversion=0.0.1-SNAPSHOT -Dpackaging=jar
mvn install:install-file -Dfile=../app-root/runtime/repo/shared-models-skychart-0.0.1-SNAPSHOT.jar -DgroupId=com.systix -DartifactId=shared-models-skychart -Dversion=0.0.1-SNAPSHOT -Dpackaging=jar
UPDATE 2: Also, the above pom.xml is what I have in my project code files. However, when I ssh intoopenshift servers and review the local maven repos, the following is what I see as pom.xml
cat ./.m2/repository/com/systix/shared-helper-data-skychart/0.0.1-SNAPSHOT/shared-helper-data-skychart-0.0.1-SNAPSHOT.pom
<?xml version="1.0" encoding="UTF-8"?>
<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"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>
<groupId>com.systix</groupId>
<artifactId>shared-helper-data-skychart</artifactId>
<version>0.0.1-SNAPSHOT</version>
<description>POM was created from install:install-file</description>
</project>
This is what worked for me:
I connected via SSH to OpenShift like described here.
There I found out that in the OpenShift maven repo (under ~/.m2/repository/) the jar had not been installed correctly. In the dependency directory there were *.jar.lastUpdated files instead of the actual jars.
I deleted the whole directory of the problematic dependency from the maven repo (manually)
In my pre_build action hook I changed mvn install:install -Dfile path to an absolute path to the jar (e.g. /var/lib/openshift/___your__id__here____/app-root/runtime/repo/dependencyfile.jar
I pushed my local changes (pre_build action hook changed in point 4.) to the git repo. Now all worked fine :)

Resources