Jenkins master正在Windows上運行。我使用java webstart連接了一個MAC作爲jenkins slave。我已經在從站(MAC)中安裝了ANT並相應地更新了PATH。我能夠在奴隸機器上本地運行螞蟻程序。Jenkins無法在MAC Slave中調用ANT
當我從詹金斯運行的作業,它不是調用螞蟻和失敗與下面的錯誤。 請說明。
Building remotely on QAXXX in workspace /Users/uselvvi/jenkins/workspace/QG_LOCALIZATION_STAGING
Cleaning up /Users/uselvvi/jenkins/workspace/QG_LOCALIZATION_STAGING/.
Updating https://<SVNRepo>/SVN at revision '2014-03-24T15:55:41.180 -0500'
At revision 1196
no change for https://<SVNRepo>/SVN since the previous build
[QG_LOCALIZATION_STAGING] $ ant -DLOCALE=en_US -DBROWSER=IE -DENVIRONMENT=QA1 -DSUITE=STAGING RunTestNGSuite
FATAL: command execution failed.Maybe you need to configure the job to choose one of your Ant installations?
java.io.IOException: Cannot run program "ant" (in directory "/Users/uselvvi/jenkins/workspace/QG_LOCALIZATION_STAGING"): error=2, No such file or directory
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1042)
at hudson.Proc$LocalProc.<init>(Proc.java:244)
at hudson.Proc$LocalProc.<init>(Proc.java:216)
at hudson.Launcher$LocalLauncher.launch(Launcher.java:773)
at hudson.Launcher$ProcStarter.start(Launcher.java:353)
at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:998)
at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:965)
at hudson.remoting.UserRequest.perform(UserRequest.java:118)
at hudson.remoting.UserRequest.perform(UserRequest.java:48)
at hudson.remoting.Request$2.run(Request.java:328)
at hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at hudson.remoting.Engine$1$1.run(Engine.java:63)
at java.lang.Thread.run(Thread.java:744)
Caused by: java.io.IOException: error=2, No such file or directory
at java.lang.UNIXProcess.forkAndExec(Native Method)
at java.lang.UNIXProcess.<init>(UNIXProcess.java:185)
at java.lang.ProcessImpl.start(ProcessImpl.java:134)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1023)
... 15 more
Build step 'Invoke Ant' marked build as failure
Archiving artifacts
Finished: FAILURE
編輯:我正在使用'調用ANT'。相同的設置在Windows從屬工作正常。
這看起來並不像詹金斯的Ant生成步驟調用。你正在使用**調用Ant ** Jenkins構建步驟,還是使用** Execute Shell **並在那裏輸入「ant」? – Slav
您好,先生,我正在使用invoke ANT – vins
我所能想到的是:確保在您的** Invoke Ant **構建步驟中,您的_Ant Version_被設置爲默認值(這將使用系統中設置的任何值)。另外,我假設,當你說你在本地測試它時,測試是用我在日誌中看到的相同'uselvvi'用戶完成的。 – Slav