Allow for jinja2 templating of puppet_config

In support of the wider Multi-RHEL effort. We will
need to support templating to allow for Ansible to
determine which container needs to be pulled to
the hosts based on their OS version.

This change adds support for that templating of
the puppet_config files.

Change-Id: I5b6a34c4013ad86585bdbd29dab882dd0dd1b3e2
This commit is contained in:
Brendan Shephard 2022-08-22 11:57:49 +10:00
parent 3d40e77a66
commit 524242606f
1 changed files with 1 additions and 1 deletions

View File

@ -108,7 +108,7 @@
become: true
no_log: True
copy:
content: "{{ lookup('file', tripleo_role_name + '/puppet_config.yaml', errors='ignore') | default([], True) | from_yaml | to_nice_json }}"
content: "{{ lookup('template', tripleo_role_name + '/puppet_config.yaml', errors='ignore') | default([], True) | from_yaml | to_nice_json }}"
dest: /var/lib/container-puppet/{{ ansible_check_mode | bool | ternary('check-mode/', '') }}container-puppet.json
force: true
mode: '0600'