How to make a ssh connection in jenkins workflow through Groovy sand box

762 views
Skip to first unread message

karthik m

unread,
Jul 23, 2015, 1:10:37 PM7/23/15
to Jenkins Users
We are using a workflow in Jenkins

and we need to run a script with particular user previlages, so we should make a ssh connection to server and then run that script, we need to implement this in  Groovy sand box.


 note:ssh connection should be a password less
please Help in doing this

Baptiste Mathus

unread,
Jul 24, 2015, 2:51:30 AM7/24/15
to jenkins...@googlegroups.com

I'd look at using the publish over SSH plugin inside the workflow code.

Cheers

--
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-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-users/88d634ba-e724-489a-96b4-fc65b59c1c0b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Jesse Glick

unread,
Aug 12, 2015, 5:07:45 PM8/12/15
to Jenkins Users
On Thursday, July 23, 2015 at 1:10:37 PM UTC-4, karthik m wrote:
We are using a workflow in Jenkins

and we need to run a script with particular user previlages, so we should make a ssh connection to server and then run that script

Try using the new release of the SSH Agent plugin, which includes a block-scoped workflow step to load SSH private key credentials. 
Reply all
Reply to author
Forward
0 new messages