github-api-global-lib icon indicating copy to clipboard operation
github-api-global-lib copied to clipboard

Difference between....?

Open donovanrost opened this issue 2 years ago • 1 comments

Is there a technical difference between

  sh "curl ...."

and

loadLinuxScript(name: 'script-which-calls-curl')
sh 'script-which-calls-curl'

I know the loadLinuxScript will execute on the worker. Will the inline curl execute on the worker or the master?

donovanrost avatar Aug 18 '22 02:08 donovanrost

loadLinuxScript.groovy also don't have node definition. so when we import loadLinuxScript in jenkins file according to that will pick(preferred is worker in case no executor then it should be from master). So goes to sh "curl " @darinpope please correct me if i'm wrong.

ankujuniyal avatar Apr 08 '23 12:04 ankujuniyal