Skip to content

Instantly share code, notes, and snippets.

@samdoran
Created July 30, 2018 21:50
Show Gist options
  • Select an option

  • Save samdoran/887ce92fb4c42dedb87f98c853333c8e to your computer and use it in GitHub Desktop.

Select an option

Save samdoran/887ce92fb4c42dedb87f98c853333c8e to your computer and use it in GitHub Desktop.
Deploy steps using ternary
- name: Write the puppet step_config manifest
copy:
content: "{{ puppet_step_config is defined | ternary(puppet_step_config, lookup('file', tripleo_role_name + '/step_config.pp')) }}"
dest: /var/lib/tripleo-config/puppet_step_config.pp
force: yes
mode: '0600'
- name: Write docker-puppet.json file
copy:
content: "{{ docker_puppet_config is defined | ternary(docker_puppet_config, lookup('file', tripleo_role_name + '/puppet_config.yaml')) | from_yaml | to_json }}"
dest: /var/lib/docker-puppet/docker-puppet.json
force: yes
mode: '0600'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment