Merge "Remove the "emit-ara-html" role"

This commit is contained in:
Zuul 2018-10-23 10:14:29 +00:00 committed by Gerrit Code Review
commit 08af5f0110
3 changed files with 0 additions and 90 deletions

View File

@ -1,35 +0,0 @@
**THIS ROLE IS DEPRECATED**, please use the ``ara-report`` role instead.
``ara-report`` provides the same default behavior with the generation of a HTML
report and provides additional functionality that can be used to dynamically
load databases for improved performance and scalability.
Have ARA generate html logs if ARA and ARA data are both present.
**Role Variables**
.. zuul:rolevar:: ara_generate_html
Whether to generate a static ARA HTML report or not.
Possible values:
- ``true`` (always generate a report)
- ``false`` (never generate a report)
- ``failure`` (only generate a report on failure)
Defaults to ``true``.
.. zuul:rolevar:: ara_compress_html
Whether to compress the ARA HTML output or not.
Defaults to ``true``.
.. zuul:rolevar:: ara_save_database
Whether the ARA sqlite database should be saved as part of the logs.
Defaults to ``false``.
.. tip::
Make sure the web server is configured to set the required mimetypes_ in
order to serve gzipped content properly.
.. _mimetypes: https://git.openstack.org/cgit/openstack-infra/puppet-openstackci/tree/templates/logs.vhost.erb?id=5fe1f3d2d5e40c2458721e7dcf8631d62ea2525f#n24

View File

@ -1,12 +0,0 @@
# Whether to generate a static ARA HTML report or not
# Possible values:
# - true (always)
# - false (never)
# - 'failure' (only on failure)
ara_generate_html: true
# Whether to compress the ARA HTML output or not
ara_compress_html: true
# Whether to save the ARA sqlite database as part of the logs or not
ara_save_database: false

View File

@ -1,43 +0,0 @@
- name: Warn about deprecated role
debug:
msg: |
The emit-ara-html role is deprecated.
Please use the ara-report role instead.
- name: Check for ARA db
stat:
path: "{{ zuul.executor.work_root }}/.ara/ansible.sqlite"
register: ara_db_stat
- name: Save the ARA database
command: |
cp "{{ zuul.executor.work_root }}/.ara/ansible.sqlite" \
{{ zuul.executor.log_root }}
when:
- ara_db_stat.stat.exists
- ara_save_database | bool
- name: Check for ARA install
command: bash -c "type -p ara"
ignore_errors: yes
register: ara_command_type
when: ara_db_stat.stat.exists
- when:
- ara_command_type.rc == 0
- not ara_command_type | skipped
block:
# Always generate (true), never (false) or only on failure ('failure')
# Additionally cover for edge cases where zuul_success might be undefined
- name: Generate ARA html output
command: "ara generate html {{ zuul.executor.log_root }}/ara"
ignore_errors: yes
when: ara_generate_html | bool or
(ara_generate_html == 'failure' and not zuul_success | default(false) | bool)
register: ara_generated
- name: Compress ARA html output
command: gzip --recursive --best {{ zuul.executor.log_root }}/ara
ignore_errors: yes
when:
- not ara_generated | skipped