ansible-slurm-appliance icon indicating copy to clipboard operation
ansible-slurm-appliance copied to clipboard

Can't override environment-defined config in packer build

Open sjpb opened this issue 3 years ago • 1 comments

Because builder is near the start of the alphabet it is impossible to override group_vars defined in a concrete environment (rather than common/.../all).

e.g.: environments/myenv/inventory/group_vars/compute/defaults.yml is not overriden by myenv/.../builder/overrides.yml

Not sure how to fix this. Changing builder group to be near the end of the alphabet, e.g. xtrabuilder does not do it,

sjpb avatar May 11 '21 10:05 sjpb

Potential workaround for such issues:

environments/myenv/inventory/group_vars/compute/defaults.yml:

some_value: "{{ some_value_override | default('default-value') }}"

myenv/.../builder/overrides.yml:

some_value_override: my-override

But yeah, a little bit hairy...

jovial avatar May 11 '21 14:05 jovial