Hi Robert,

The first step, is to check the compilation before playing the tests.
For this, there's an option in the docker run command such as -DskipTests in maven.
Here is the command:

docker run -v $PWD/.m2:/root/.m2 -v $PWD:/origin -v
$PWD/dockerfiles/run/spring/destination:/destination -t james/project -s master

You also have to give the git SHA1 of the commit, it's working with branch names (master in this example).

We are playing test on each commits on the master branch in our CI,
so this branch is clean and all tests are passing.

The error you encounter is may be because the docker container can't join the docker-engine in order to launch extra-containers used by tests.
There's a paragraph for that in the README under the Java 8 section.

Antoine


Le 31/05/2017 à 02:05, Robert Munn a écrit :
Hi, I'm doing some work with James again and I want to compile the latest
version. I tried the docker-compose.yml route but that didn't build
successfully. I'm following directions here:

https://github.com/apache/james-project

I am using this URL as my remote:

http://git-wip-us.apache.org/repos/asf/james-project.git


I have cloned the source into my local environment. I can build the Docker
image using this command:

docker build -t james/project dockerfiles/compilation/java-8

When I get to this command:

docker run -v $PWD/.m2:/root/.m2 -v $PWD:/origin -v
$PWD/dockerfiles/run/spring/destination:/destination -t james/project

I get test failures and the process aborts. It suggests a route to resume
the build rather than restart it, though I'm not clear on whether I can
restart the mvn process from outside Docker. Details of the error are here:

[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 02:23 h
[INFO] Finished at: 2017-05-30T21:47:39Z
[INFO] Final Memory: 176M/790M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-surefire-plugin:2.19:test (default-test) on
project apache-james-mpt-smtp-cassandra: There are test failures.
[ERROR]
[ERROR] Please refer to
/james-project/mpt/impl/smtp/cassandra/target/surefire-reports for the
individual test results.
[ERROR] -> [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
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the
command
[ERROR]   mvn <goals> -rf :apache-james-mpt-smtp-cassandra


Is there a good SHA hash I can build from, or does anyone have another
suggestion about getting a good compilation?

BTW, I am on macOS Sierra, though I can build against a Linux VM if that
makes any difference.

I have an older version that I can run in the meantime, but I'd love to get
something more current.

Thanks,

Robert



---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscr...@james.apache.org
For additional commands, e-mail: server-user-h...@james.apache.org

Reply via email to