There are different ways to specify environment variables in Jenkins. To specify an environment variable that applies globally, go to the Jenkins configuration pages. You can also specify environment variables that only apply to individual nodes, or ones that are set as an external step before starting Jenkins.
In a scenario where you have Visual COBOL installed on multiple platforms on agent machines, using environment variables for common installation paths can greatly simplify the creation of new projects.
For example, you can have an environment variable for the Visual COBOL installation directory on Windows, and another one for the corresponding location on UNIX. Other environment variables could point to locations such as the installation location of , the default source code control system check-out folder, or the location of the samples.
To set global environment variables in Jenkins:
To set environment variables for a node: