繁体   English   中英

从Windows机器到Linux的Ant自动化

[英]Ant automation from windows machine to linux

我在Windows计算机上运行ant脚本。 从Windows,我登录到Linux服务器并运行一些基本命令。

有没有办法使用ant脚本或任何脚本方法使其自动化?

是。

在下面的示例中,我安装了安装程序为Multiplatform并在Windows机器上创建的应用程序,并且在Linux机器上运行了命令(复制到linux机器后)。

我建议您使用plink.exe,pscp.exe。

echo'处理安装文件 '%Jenkins_tools%\\ pscp.exe -pw“%Install_path%\\%installation% Unix %newversion%.sh” root @%server_ip%:/ opt /

%Jenkins_tools%\\ pscp.exe -pw“ C:\\ Jenkins \\ deployment \\ responsefiles \\%installation%\\ response.varfile” root @%server_ip%:/ opt /

echo' *运行安装 '%Jenkins_tools%\\ plink.exe -ssh root @%server_ip%-P 22 -pw chmod + x / opt /%installation%

%Jenkins_tools%\\ plink.exe -ssh root @%server_ip%-P 22 -pw /opt/%installation%*.sh -varfile /opt/response.varfile -q

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM