Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Jenkins : How to add custom tool to my job's build environment

I define a custom tool in Jenkins and I would like to run it during a build. In "https://wiki.jenkins.io/display/JENKINS/Custom+Tools+Plugin" I see the following : "Then, you just need to add the tool requirement to your job's Build Environment" but I cannot find such an option anywhere. Where can I find it? Or is there another way to run the installation of the custom tool?

like image 507
Ivajlo Iliev Avatar asked Oct 20 '25 15:10

Ivajlo Iliev


1 Answers

Is this a Pipeline? If it is, you can include it in the pipeline file under 'environment', prior to the stages, like so:

pipeline {
  agent any
  options {
    timestamps()
  }
  environment {
      TOOL = tool name: '<tool>', type:     'com.cloudbees.jenkins.plugins.customtools.CustomTool'
  }
  stages {
...
}
like image 96
Sean C Avatar answered Oct 22 '25 05:10

Sean C



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!