env:
- name: FIELDREF_ENV
valueFrom:
fieldRef:
fieldPath: metadata.name
As with pod environment variables, build environment variables can be defined in terms of references to other resources/variables using the Downward API. However, there are some exceptions as noted below.
You can also manage environment variables defined in the |
You can inject information about the build object by setting the fieldPath
environment variable source to the JsonPath
of the field from which you are
interested in obtaining the value.
env:
- name: FIELDREF_ENV
valueFrom:
fieldRef:
fieldPath: metadata.name
Jenkins Pipeline strategy does not support |