From 5f77e303f19bf7da3b57137f5718d675052fa82f Mon Sep 17 00:00:00 2001 From: Hao Liu <44379968+TheRealHaoLiu@users.noreply.github.com> Date: Tue, 21 May 2024 13:55:15 -0400 Subject: [PATCH] Improve logging in CI - Set AWX log level to DEBUG - Fix failure to collect awx API output --- molecule/default/tasks/awx_test.yml | 7 +++++++ molecule/default/templates/awx_cr_molecule.yml.j2 | 3 +++ 2 files changed, 10 insertions(+) diff --git a/molecule/default/tasks/awx_test.yml b/molecule/default/tasks/awx_test.yml index aaac0b828..166178b99 100644 --- a/molecule/default/tasks/awx_test.yml +++ b/molecule/default/tasks/awx_test.yml @@ -139,6 +139,13 @@ controller_password: "{{ admin_pw_secret.resources[0].data.password | b64decode }}" rescue: + - name: Create debug output directory + ansible.builtin.file: + path: '{{ debug_output_dir }}' + state: directory + tags: + - always + - name: Get list of project updates and jobs uri: url: "http://localhost/awx/api/v2/{{ resource }}/" diff --git a/molecule/default/templates/awx_cr_molecule.yml.j2 b/molecule/default/templates/awx_cr_molecule.yml.j2 index 16b68373d..3f11c69ae 100644 --- a/molecule/default/templates/awx_cr_molecule.yml.j2 +++ b/molecule/default/templates/awx_cr_molecule.yml.j2 @@ -42,6 +42,9 @@ spec: additional_labels: - my/team - my/service + extra_settings: + - setting: LOG_AGGREGATOR_LEVEL + value: "'DEBUG'" {% if additional_fields is defined %} {{ additional_fields | to_nice_yaml | indent(2) }} {% endif %}