Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-631

Improve slave Unix/Windows detection and perform error check

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • remoting
    • None
    • Platform: All, OS: All

      Create an ant build and it works fine on master.
      the output is as follows...

      [ProjectName] $ cmd.exe /C ant.bat publish

      but tie this build to a slave the output becomes

      [ProjectName] $ ant publish

      And the error stack trace...
      FATAL: command execution failed
      java.io.IOException: CreateProcess: ant publish
      at java.lang.ProcessImpl.create(Native Method)
      at java.lang.ProcessImpl.<init>(Unknown Source)
      at java.lang.ProcessImpl.start(Unknown Source)
      at java.lang.ProcessBuilder.start(Unknown Source)
      at java.lang.Runtime.exec(Unknown Source)
      at hudson.Proc$LocalProc.<init>(Proc.java:79)
      at hudson.Launcher$LocalLauncher.launch(Launcher.java:167)
      at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:251)
      at hudson.Launcher$RemoteLaunchCallable.call(Launcher.java:235)
      at hudson.remoting.UserRequest.perform(UserRequest.java:57)
      at hudson.remoting.UserRequest.perform(UserRequest.java:22)
      at hudson.remoting.Request$2.run(Request.java:178)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown
      Source)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)

      If you attempt to do Runtime.getRuntime.exec("ant publish"); you get the same
      issue. For some reason the ant invocation is not generating as ant.bat which is
      what it needs to be generated as.

            Unassigned Unassigned
            mwiles mwiles
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: