Bug 1458018
Summary: | [RFE] Enable ansible logging by default | ||
---|---|---|---|
Product: | OpenShift Container Platform | Reporter: | Eric Jones <erjones> |
Component: | Installer | Assignee: | Scott Dodson <sdodson> |
Status: | CLOSED ERRATA | QA Contact: | Johnny Liu <jialiu> |
Severity: | high | Docs Contact: | |
Priority: | unspecified | ||
Version: | 3.0.0 | CC: | aos-bugs, erich, jokerman, mmccomas, rybrown, sdodson, tibrahim |
Target Milestone: | --- | Keywords: | Reopened |
Target Release: | 3.11.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Enhancement | |
Doc Text: |
The ansible.cfg file distributed with openshift-ansible now sets a default log path of ~/openshift-ansible.log. This ensures that logs are written in a predictable location by default.
In order to use the distributed ansible.cfg file you must first change directories to /usr/share/ansible/openshift-ansible before running playbooks.
This ansible.cfg also sets other options meant to increase performance and reliability of openshift-ansible.
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 2018-10-11 07:19:06 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Eric Jones
2017-06-01 19:06:52 UTC
Is the suggestion here that OpenShift override the default ansible configuration files so that they log anible run's to logs by default? Ansible takes configuration from projects as well. For example, if we had the OpenShift install playbooks in a directory like this: os-ansible-installer/ - roles/ - roleA/ - roleB/ - vars/ - main.yml - site_vault.yml - install_openshift_playbook.yml - ansible.cfg If, in the ansible.cfg, the OpenShift team supplied overrides to Ansible's logging options, then runs of `install_openshift_playbook.yml` would pick up those and any other configs in ansible.cfg. So there's no need to override system config. (In reply to Ryan Brown from comment #9) > If, in the ansible.cfg, the OpenShift team supplied overrides to Ansible's > logging options, then runs of `install_openshift_playbook.yml` would pick up > those and any other configs in ansible.cfg. So there's no need to override > system config. Here: https://github.com/openshift/openshift-ansible/blob/master/ansible.cfg#L10 We need to update ansible.cfg to ensure that it logs and update the documentation to have them change directories to /usr/share/ansible/openshift-ansible prior to running playbooks. https://github.com/openshift/openshift-ansible/pull/9247 Sets log path to ~/openshift-ansible.log We'll open a docs pr that instructs people to cd /usr/share/ansible/openshift-ansible prior to running playbooks. Verified this bug with openshift-ansible-3.11.0-0.10.0.git.0.91bb588None.noarch, and PASS. # pwd /usr/share/ansible/openshift-ansible # cat ansible.cfg <--snip--> [defaults] # Set the log_path log_path = ~/openshift-ansible.log <--snip--> # cat ~/openshift-ansible.log cat: /root/openshift-ansible.log: No such file or directory # ansible-playbook -i /tmp/qe-inventory-host-file playbooks/openshift-checks/pre-install.yml # ll ~/openshift-ansible.log -rw-r--r--. 1 root root 75873 Aug 3 04:27 /root/openshift-ansible.log Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:2652 |