Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions src/roles/post_install/tasks/foreman-proxy-content.yaml

This file was deleted.

14 changes: 11 additions & 3 deletions src/roles/post_install/tasks/main.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,14 @@
---
- name: Run post install tasks
ansible.builtin.include_tasks: "{{ flavor }}.yaml"

- name: Check for unrecognized Smart Proxy features
ansible.builtin.include_tasks: smart_proxy_features_check.yaml

- name: Post install message
ansible.builtin.include_tasks: message.yaml

- name: Mark installation as complete
ansible.builtin.copy:
dest: "{{ post_install_done_flag }}"
content: ''
mode: '0640'
delegate_to: localhost
become: false
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@
---
- name: Admin credentials
- name: Post install message
when: flavor in ['katello']
ansible.builtin.debug:
msg:
- "{{ _post_install_url_msg }}"
- "{{ _post_install_cred_msg if (post_install_done_flag is not exists) else '' }}"
vars:
_post_install_url_msg: "Foreman is running at {{ post_install_foreman_server_url }}"
_post_install_cred_msg: "Admin credentials: {{ post_install_foreman_initial_admin_username }}:{{ post_install_foreman_initial_admin_password }}"
- name: Mark installation as complete
ansible.builtin.copy:
dest: "{{ post_install_done_flag }}"
content: ''
mode: '0640'
delegate_to: localhost
become: false
11 changes: 8 additions & 3 deletions src/roles/post_install/tasks/smart_proxy_features_check.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
msg: >-
Proxy {{ item.name }} reports unrecognized features: {{ item.unrecognized_features | join(', ') }}.
Enable matching features in foremanctl or disable them on the proxy.
loop: "{{ _post_install_smart_proxies.resources }}"
when:
- item.unrecognized_features | default([]) | length > 0
loop: "{{ _post_install_proxies_with_unrecognized_features }}"
loop_control:
label: "{{ item.name }}"
vars:
_post_install_proxies_with_unrecognized_features: >-
{{ _post_install_smart_proxies.resources |
selectattr('unrecognized_features', 'defined') |
selectattr('unrecognized_features', '!=', []) | list }}