How to pass custom variable to Jenkins

Hi All,

i am using below URI to trigger build in Jenkins…

URI:
http://192.168.104.234:8080/job/Smoke_Testing/buildWithParameters?DIFF_ID={buildable.diff}&PHID={target.phid}

here i need to pass custom variable apart from buildable.diff and target.phid

i have so many features for testing, based on the custom variable it will run test only particular feature

for example if am passing “DHCP ZTP”, it will trigger only particular feature through jenkins build. can anyone please help on this…

I don’t think you actually can provide custom stuff there - see https://secure.phabricator.com/T10517 for the task.

How would you calculate the DCHP ZTP value? Can you just hard-code it into the URI?

I think last time I had to do something like that, I put the logic about which tests to run in the Jenkins side (which included making API calls to Phabricator to get more information).

Hi avivey,

Please find URI am trying to pass…

http://192.168.104.234:8080/job/Smoke_Testing/buildWithParameters?DIFF_ID={buildable.diff}&PHID={target.phid}&Feature={feature_list}

if the feature_list contains DHCP, Jenkins will run testcases related to DHCP
or if the feature_list contains “DHCP ZTP”, jenkins job will trigger testcases related to DHCP and ZTP

Thanks in Advance…