Maven build fails on an Ant FTP task failure
Posted
by fraido
on Stack Overflow
See other posts from Stack Overflow
or by fraido
Published on 2010-04-19T11:00:58Z
Indexed on
2010/04/19
11:03 UTC
Read the original article
Hit count: 309
I'm using the FTP Ant task with maven-antrun-plugin
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>ftp</id>
<phase>generate-resources</phase>
<configuration>
<tasks>
<ftp action="get"
server="${ftp.server.ip}"
userid="${ftp.server.userid}"
password="${ftp.server.password}"
remotedir="${ftp.server.remotedir}"
depends="yes" verbose="yes"
skipFailedTransfers="true"
ignoreNoncriticalErrors="true">
<fileset dir="target/test-classes/testdata">
<include name="**/*.html" />
</fileset>
</ftp>
</tasks>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
</executions>
...
the problem is that my build fails when the folder ${ftp.server.remotedir} doesn't exist.
I tried to specify
skipFailedTransfers="true"
ignoreNoncriticalErrors="true
but these don't fix the problem and the build keeps failing.
An Ant BuildException has occured: could not change remote directory: 550 /myBadDir: The system cannot find the file specified.
Do you know how to instruct my maven build to don't care about this Ant task error
© Stack Overflow or respective owner