Skip to content

Commit

Permalink
Clean up kickstart post if else (#289)
Browse files Browse the repository at this point in the history
* Clean up kickstart post is else

* Add fragment

* Fix lint
  • Loading branch information
matoval authored Sep 7, 2023
1 parent e7860c9 commit 537d72c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions changelogs/fragments/289-clean-up-kickstart-post-if-else.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
minor_changes:
- Clean up kickstart post if else
2 changes: 1 addition & 1 deletion roles/builder/vars/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ builder_kickstart_options:
- ostreesetup --nogpg --osname=rhel --remote=edge --url=http://{{ builder_system_ipv4 }}/{{ builder_blueprint_name }}/repo/ --ref={{ builder_blueprint_ref }} # noqa yaml[line-length]
_builder_kickstart_post:
- "{{ lookup('ansible.builtin.template', '../templates/auto_register_aap.j2') if builder_aap_url is defined | default(None) }}"
builder_kickstart_post: "{{ _builder_kickstart_post + additional_kickstart_post if additional_kickstart_post is defined else _builder_kickstart_post }}"
builder_kickstart_post: "{{ _builder_kickstart_post + additional_kickstart_post if additional_kickstart_post is defined else (_builder_kickstart_post if _builder_kickstart_post is defined ) | default(None) }}" # yamllint disable-line rule:line-length
_builder_pub_key: "{{ builder_pub_key if builder_pub_key is defined else (builder_pub_key_path if builder_pub_key_path is defined else '') }}"
_builder_compose_type: "{{ ('iot-commit' if ansible_distribution == 'Fedora' else 'edge-commit') if 'installer' in builder_compose_type or 'raw' in builder_compose_type else builder_compose_type }}" # yamllint disable-line rule:line-length

0 comments on commit 537d72c

Please sign in to comment.