I have a Jenkins Windows install and a bash script that needs to run in wsl as part of my build process.
The build stage runs, but never stops and I have to terminate it manually. There is nothing in the Console Output to indicate where the script gets to.
Currently, I have stripped the script back to “echo hello” and still have the problem.
Is it possible to run wsl, or am I approaching this the wrong way?
Your Jenkins installation is a standard Windows installation, not an install of Jenkins thanks to the package manager in WSL, right?
What kind of agent are you using? Is it the Built-In Node, or did you install something in WSL?
I see, Martin.
I’m sorry but don’t know how to get the built-in agent to launch something on WSL.
I would expect a WSL agent would be the way to go, but I’m in no way an expert.
I started a WSL window on my Windows 11 computer and from inside that window I ran a Jenkins agent process that connected to my controller. It runs shell steps and reports the expected results. I used a swarm agent to do it, though I’m confident that any inbound agent could be used.
An ssh agent on WSL seems unlikely, since the Windows Subsystem for Linux would need to be listening on the SSH port for the entire system.