Enable ARA for the undercloud install

In the latest versions of the undercloud install, ansible is used.
Use ARA to profile the undercloud install steps as driven by TripleO
and save the ARA report to logs/ara_oooq_root/

Change-Id: I2b034b83ba7779d15a5d69263e67d3aea3f631a8
This commit is contained in:
Wes Hayutin 2018-06-14 15:37:49 -04:00 committed by wes hayutin
parent 30a455e53d
commit fa0c65604a
4 changed files with 54 additions and 0 deletions

View File

@ -23,6 +23,15 @@
{% if artcl_gzip_only|bool %}gzip --best --recursive {{ artcl_collect_dir }}/ara_oooq;{% endif %}
ignore_errors: yes
- name: Generate and retrieve root the ARA static playbook report
become: yes
shell: >
{{ local_working_dir }}/bin/ara generate html {{ local_working_dir }}/ara_oooq_root;
{{ local_working_dir }}/bin/ara task list --all -f json > {{ artcl_collect_dir }}/ara.oooq.root.json;
cp -r {{ local_working_dir }}/ara_oooq_root {{ artcl_collect_dir }}/;
{% if artcl_gzip_only|bool %}gzip --best --recursive {{ artcl_collect_dir }}/ara_oooq_root;{% endif %}
ignore_errors: yes
- include: ara_graphite.yml
when: ara_graphite_server is defined
ignore_errors: yes

View File

@ -28,3 +28,5 @@ custom_nameserver:
# default value for undercloud_rpm_dependencies
# is in extras-common
undercloud_ansible_cfg: true

View File

@ -0,0 +1,37 @@
---
# Configure the undercloud to use ARA
# for ansible undercloud or standalone only. Ansible deployment of node
- name: Install ara dependencies
become: true
pip:
name: "{{ item }}"
with_items:
- flask
- ara
- name: Update the default ansible callback setting in /etc/ansible/ansible.cfg
become: true
lineinfile:
path: /etc/ansible/ansible.cfg
regexp: '^#callback_plugins'
line: |
callback_plugins=/usr/lib/python2.7/site-packages/ara/plugins/callbacks
- name: Update the default ansible action setting in /etc/ansible/ansible.cfg
become: true
lineinfile:
path: /etc/ansible/ansible.cfg
regexp: '^#action_plugins'
line: |
action_plugins=/usr/lib/python2.7/site-packages/ara/plugins/actions
- name: Update the default ansible library setting in /etc/ansible/ansible.cfg
become: true
lineinfile:
path: /etc/ansible/ansible.cfg
regexp: '^#library'
line: |
library=/usr/lib/python2.7/site-packages/ara/plugins/modules

View File

@ -26,3 +26,9 @@
include: hostname.yml
when: hostname_correction|bool or step_set_undercloud_hostname|bool
- name: Include ansible.cfg configuration for the undercloud / node
include: ansible_cfg.yml
when:
- undercloud_ansible_cfg|bool
- containerized_undercloud|bool