I am provisioning a guest windows machine (both win7 and 10) with Vagrant and I want to start a process on the guest (the selenium server jar) that is visible to the guest. In other words, when the user logs into the gui I want the command window sitting there open running my jar.
How can I do this?
I've been able to start the process using vagrant's shell provisioning to run a ps1 file but it is always hidden when I log into the gui.
Here is the shell portion of my Vagrantfile:
win7.vm.provision "shell", path: "start_selenium.ps1", powershell_args: "-WindowStyle Normal"
And here is start_selenium.ps1:
$selenium_out = "C:\sel\selenium.jar"
$java = "C:\Program Files\Java\jre*\bin\java.exe"
Start-Process $java -ArgumentList '-jar', $selenium_out -WindowStyle normal