Hi Eric,
Since builduser has bash as the default shell, you will be in the bash shell.

You can do some testing. Remember that you can probably run ssh from the host.
  ssh -f builduser@buildMachine "echo Computername is set to: $COMPUTERNAME"

I think the script is assuming that HOSTNAME is already set on Linux boxes.
Put the following 5 lines in a script file on your host - I took most of it 
from your command line.

#!/bin/bash
. ~/.bash_profile
export HOSTNAME=`hostname`
cd /app/rosstr/build
/opt/apache-ant-1.7.1/bin/ant -f build.xml -Dfull.buildnumber=3.0.2.8


I have made a couple of assumptions here. Make sure that you get the machine 
name from:
  ssh -f builduser@buildMachine hostname

Line 3 sets the HOSTNAME variable, which should work. If not, try setting 
COMPUTERNAME.
You need to make the script executable - just in case you don't know, if the 
script is called "ant.start", the command would be:
  chmod a+x ant.start

And you would run it with:
  ssh -f builduser@buildMachine ant.start

Hope this helps,
Rob


-----Original Message-----
From: Eric Fetzer [mailto:elstonk...@yahoo.com] 
Sent: Tuesday, May 08, 2012 10:10 AM
To: Ant Users List
Cc: Ant Users List
Subject: Re: Build directly on machine vs. SSH to machine and start build

Bash is this user's default shell.



On May 8, 2012, at 9:41 AM, Eric Fetzer <elstonk...@yahoo.com> wrote:

> Robert,
> 
> Notice in my command:
> 
>>>> ssh -f builduser@buildMachine ". ~/.bash_profile;cd 
>>>> /app/rosstr/build;/opt/apache-ant-1.7.1/bin/ant -f build.xml 
>>>> -Dfull.buildnumber=3.0.2.8
> 
> that I'm sourcing my bash profile, which also runs .bashrc.  Will this not 
> switch me to the bash shell.  I typed in here that I bash, but that's just a 
> habit because many of the users I log onto systems with don't have bash as 
> the default shell.  I'll check this one.  If not, do you think changing his 
> default would fix this?
> 
> Thanks,
> Eric
> 
> 
> 
> On May 8, 2012, at 9:13 AM, "Echlin, Robert" <robert.ech...@windriver.com> 
> wrote:
> 
>> Dfull.buildnumber=3.0.2.8

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


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

Reply via email to