How to pass shell script value to trigger remote parameterized job

10 views
Skip to first unread message

sureshco...@gmail.com

unread,
Jul 12, 2018, 10:17:30 AM7/12/18
to Jenkins Users
Hi All,

Am using 2 jenkins machines names are test1 and test2 

test1 will trigger test2 by using remote trigger parameter job         

In test1 jenkins 

I have shell script which gives one value the same i want to use in as remote parameters 

I have a remote trigger parameterized job which contains parameters 
    
Question 

How can i use shell script variable and its value to pass in the remote parameters 

I tried 

Inject environment variables to the build process

At properties content which is working fine but that is only simple value

At script content i executed value=`pwd` the same am giving in remote parameters like below

value1=${value}

In test2 jenkins am passing as string parameter as value1

The out put is ${value } but am expecting exact value of pwd














sureshco...@gmail.com

unread,
Jul 12, 2018, 10:32:31 AM7/12/18
to Jenkins Users
How to pass shell script value to trigger remote parameterized job

Balaji Lalapeta

unread,
Jul 13, 2018, 2:06:45 AM7/13/18
to jenkins...@googlegroups.com
Please use the export command..
ex: export var=$(echo $value)

On Thu, Jul 12, 2018 at 8:02 PM <sureshco...@gmail.com> wrote:
How to pass shell script value to trigger remote parameterized job

--
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/587fa9e4-465b-4811-8636-3c00685919a5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


--
 
 
Thanks & Regards,
Balaji
Reply all
Reply to author
Forward
0 new messages