title: How to start Owasp zap server(exe or jar) from jenkins
body: <p>Actually, the main issue is if I start the server then my next commond will never trigger as it always running as zap server in listening mode.
  Can I run two command line in Jenkins. I have added 2 "Execute Windows batch command" still nothing works. I have added the image in same thread</p>
  
  <p>I have tried by creating a batch file</p>
  
  <pre><code>cd /
  cd C:\Program Files\OWASP\Zed Attack Proxy
  start java -jar zap-2.6.0.jar
  </code></pre>
  
  <p>I am getting error as below after using above batch file</p>
  
  <pre><code>Process leaked file descriptors. See https://jenkins.io/redirect/troubleshooting/process-leaked-file-descriptors for more information
  </code></pre>
  
  <p><a href="https://wiki.jenkins.io/display/JENKINS/Spawning+processes+from+build" rel="nofollow noreferrer">https://wiki.jenkins.io/display/JENKINS/Spawning+processes+from+build</a></p>
  
  <p>I have also use command line arugument directly in "Execute window batch command" like:-</p>
  
  <pre><code>java -jar zap-2.6.0.jar
  </code></pre>
  
  <p>But the UI of zap is not starting</p>
  
  <p>I have also tried "<code>Windows Exe Runner Plugin</code>" </p>
  
  <p><a href="https://wiki.jenkins.io/display/JENKINS/Windows+Exe+Runner+Plugin" rel="nofollow noreferrer">https://wiki.jenkins.io/display/JENKINS/Windows+Exe+Runner+Plugin</a></p>
  
  <p>But jenkins not allowing me to put an exe name in configuration. Looks like a bug of jenkins.</p>
  
  <p>I have also tried by adding zap in environmental variable but that also not working.</p>
  
  <p>Now I am out of idea.</p>
  
  <p>The issue is if I am triggering zap.bat it will do not allow another command to run forward as below which is in my batch:-</p>
  
  <p><a href="https://i.stack.imgur.com/u6YS7.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/u6YS7.jpg" alt="enter image description here"></a></p>
  
  <p>Additionally, UI of zap is not open as it is open after direct clicking on zap.bat file </p>
  
  <p>I have added 2 "Execute Windows batch command" still nothing works </p>
  
  <p><a href="https://i.stack.imgur.com/Zb94I.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Zb94I.jpg" alt="enter image description here"></a></p>
  
  <p>Any suggestions will be welcome </p>