jobs.<job_id>.steps[*].env

1 minute read
On this page

Use jobs.<job_id>.steps[*].env to set environment variables for steps to use in the runner environment. You can also set variables for the entire workflow or a job.

When environment variables have matching names, the CloudBees platform uses the most specific variable. For example, env defined in a step overrides job and workflow environment variables with the same name, while the step executes. env set in a job definition overrides a workflow variable with a matching name, while the job executes.

Public actions may specify expected variables in the README file.

Example usage

steps: - name: My first action env: GIT_TOKEN: ${{ cloudbees.scm.token }} FIRST_WORD: Hello LAST_WORD: world