ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chappell, Simon P" <Simon.Chapp...@landsend.com>
Subject RE: Ant from Cron problem
Date Wed, 10 Apr 2002 14:18:02 GMT
I suspected an environment variable issue, but I would recommend having your system administrator
putting ANT_HOME (remember to export it!) in the /etc/profile or /etc/profile.d/rc.local startup
file and then it'll be available to all appropriate tasks.

Simon

-----------------------------------------------------------------
Simon P. Chappell                     simon.chappell@landsend.com
Java Programming Specialist                      www.landsend.com
Lands' End, Inc.                                   (608) 935-4526


>-----Original Message-----
>From: Mckenna, Rob [mailto:rmckenna@vignette.com]
>Sent: Wednesday, April 10, 2002 9:13 AM
>To: 'Ant Users List'
>Subject: RE: Ant from Cron problem
>
>
>ANT_HOME isn't defined in the shell the cron task runs in 
>unless you run a
>profile script as part of the cron job. eg 0 2 * * *
>/u/user/.profile.sh;yourscript.sh 
>
>-----Original Message-----
>From: Mike Lecza [mailto:mlecza@newnetco.com]
>Sent: Wednesday, April 10, 2002 10:05 AM
>To: ant-user@jakarta.apache.org
>Subject: Ant from Cron problem
>
>
>This may be more of a cron issue than an Ant issue - but sure many of
>you have done this.  Perhaps you can help.
> 
>I setup cron that calls a script that looks something like this:
> 
>#!/bin/sh
> 
>echo !!!!
>echo $ANT_HOME
>$ANT_HOME/bin/ant -logfile /export/programs/backups/antoutput 
>-buildfile
>/export/programs/backups/build-backups.xml 
>echo !!!!
> 
>In the crontab I have:
>31 * * * * root  /export/programs/backups/backup.sh
>>>/export/programs/backups/cronoutput
> 
>The buildfile simply does some echos and creates a directory.
>When I run the script from the cmd line it runs just fine (creating the
>output file and the directory).  When cron runs the script the 
>antoutput
>fille is not even created and the directory is not either.  It 
>is almost
>as if the ant command is ignored.  Here is the contents of cronoutput
>after cron runs the script
> 
>Any Ideas?
> 
>Regards
>
>--
>To unsubscribe, e-mail:   
<mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>


Mime
View raw message