You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by "Conelly, Luis (PS, GNF, Contractor)" <Lu...@gnf.com> on 2004/01/29 23:55:40 UTC
Telnet Task Issue
Hi all,
I am having an issue with <telnet> task. I am trying to execute a simple script via ant to a *nix server [Red Hat Linux release 7.2 (Enigma)]
This is the snippet of the script:
<target name="callScript">
<telnet userid="${user.id}" password="${user.id}" server="${target.server}">
<read/>
<write echo="true"> sh /scripts/k2kftp.sh </write>
<read/>
<write echo="true">exit</write>
</telnet>
</target>
And the output looks like:
Buildfile: telnet_tools.xml
callScript:
[telnet] Red Hat Linux release 7.2 (Enigma)
[telnet] Kernel 2.4.7-10 on an i686
[telnet] login:
[telnet] xxxxxx
[telnet] Password:
[telnet] sh /scripts/k2kftp.sh
[telnet] exit
BUILD SUCCESSFUL
Total time: 1 second
However, the script does not get executed. I have tried to execute simpler [such as ls], but it doesn't get a thing. Does anybody has an idea about why is this happening?
Regards
-Luis
Settings:
Workstation OS: Win2K Pro
Ant: 1.6beta2
JDK: 1.4.1_02
Server OS: Red Hat Linux release 7.2 (Enigma)