Forum Discussion

Alex-007's avatar
Alex-007
Copper Contributor
Jan 03, 2023

Expanding matrix variables in pipeline

Hi,
The matrix below provides 2 variables: 'CONTAINER' and 'DEMANDS'.
strategy:
  matrix:
    x86_64:
      CONTAINER: centos7_x86_64
      DEMANDS: docker
    aarch64:
      CONTAINER: centos8_aarch64
      DEMANDS: bf
To be used later in the pipeline:
container: $[ variables['CONTAINER'] ]
pool:
  name: MyPool
  demands:  $[ variables['DEMANDS'] ] -equals yes
While the 'CONTAINER' values expand as expected, 'DEMANDS' does not expand, so it ends up with an error:
Invalid demand '$[ variables['DEMANDS'] ] -equals yes'

Any ideas?
Thanks
No RepliesBe the first to reply

Resources