Try changing the service over to running as the local system account.  Then you 
should be able to add permissions on the share for that entire machine name. 

----- Original Message -----
From: "ChrisK" <chris....@caseware.com> 
To: jenkinsci-users@googlegroups.com 
Sent: Friday, June 14, 2013 2:48:15 PM 
Subject: Which Windows user does Jenkins run jobs on? 


Hello, 


I'm relatively new to Jenkins so bare with me if these question seems 
elementary. I have done some googling, but haven't be able to come up with 
anything that works. 

I need to perform an xcopy command from our local Jenkins machine to another 
remote machine. However, to access the remote machine I need to log in with a 
username and password. So when Jenkins executes the command it says "Invalid 
drive specification". I have tried the xcopy manually on the Jenkins server and 
it works fine since I have saved the credentials for the remote machine. It's 
only when I use Jenkins to perform the xcopy that it fails. 

Is there a way to specifically set which windows user Jenkins uses to execute 
jobs? I have tried changing the "LogOn" settings on the jenkins service and 
then restarting the service and it did not work. Or any other ways around this? 




Here is the command I need to execute:  


xcopy "C:\Program Files (x86)\Jenkins\jobs\SilkTestClassic 
Git\workspace\zz_Reorg\*" "\\qaserver\AcceptTest\Jenkins\Source\" /c /s /y /i 
/h  




Here is my console output: 


Started by user anonymous Building on master in workspace C:\Program Files 
(x86)\Jenkins\jobs\SilkTestClassic Git (qaserver)\workspace
Checkout:workspace / C:\Program Files (x86)\Jenkins\jobs\SilkTestClassic Git 
(qaserver)\workspace - hudson.remoting.LocalChannel@aee86f
Using strategy: Default
Last Built Revision: Revision 2d67c364f55926e5c1308806210ceba2918ace06 
(origin/master)
Fetching changes from 1 remote Git repository
Fetching upstream changes from origin
Commencing build of Revision 2d67c364f55926e5c1308806210ceba2918ace06 
(origin/master)
Checking out Revision 2d67c364f55926e5c1308806210ceba2918ace06 (origin/master)
[workspace] $ cmd /c call 
C:\Users\qatest\AppData\Local\Temp\hudson3277876910276465049.bat

C:\Program Files (x86)\Jenkins\jobs\SilkTestClassic Git 
(qaserver)\workspace>xcopy "C:\Program Files (x86)\Jenkins\jobs\SilkTestClassic 
Git\workspace\zz_Reorg\*" "\\qaserver\AcceptTest\Jenkins\Source\" /c /s /y /i 
/h  
Invalid drive specification
0 File(s) copied

C:\Program Files (x86)\Jenkins\jobs\SilkTestClassic Git 
(qaserver)\workspace>exit 4 
Build step 'Execute Windows batch command' marked build as failure
Finished: FAILURE 

Thank you! 







-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group. 
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com. 
For more options, visit https://groups.google.com/groups/opt_out . 
  
  

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to