0
votes

How would I go about making a Jenkins server start a .bat file, that runs forever as it starts a server program, without having Jenkins run forever until the bat file is ended manually or by error?

Could this be solved by making Jenkins call a bat file which calls the server bat file thar runs forever?

1

1 Answers

1
votes

You need to detach execution from the main process, similar to the & operator in Linux.

If you bath file is named run-forever.bat, then create another batch file named forever-starter.bat that does this :

@start "" cmd /c run-forever.bat