I have a Bamboo remote agent running a Job that basically:
-Checkout a PowerShell script in a sub-directory
- and Run the PowerShell script (This script,among others, build the code from the main directory)
This work perfectly fine when I run the remote agent manually in a terminal, but when the remote agent run as a service (installntservice), the task running the script is failing returning -1.
As I had problem with Git right to checkout the script, I have change the "bamboo-remote-agent" service "Log On As" option from " Local Service" to the windows account username. It solve the Git checkout error I had but not the script failing error.
I have added in /conf/wrapper.conf the following:
wrapper.java.additional.3=-Djava.io.tmpdir="C:\bamboo_agent\temp"
(On Windows, when the Bamboo remote agent is installed as a service under the Local System user account. The temporary folder created by the agent isn't accessible by any other application. To allow enable to that folder, configure the agent to use a commonly accessible temporary folder by defining a new Java property in the service wrapper.)
but I don't know how I can checkout my script into that temp directory and then run it from a Bamboo task.
Any help would be appreciated.
Thanks,