Update ARA
ARA's master branch now has static site generation, so we can move away from the stable branch and get the new reports. In the mean time ARA upstream has moved to github, so this updates the references for the -devel job. Depends-On: https://review.opendev.org/c/openstack/project-config/+/793530 Change-Id: I008b35562994f1205a4f66e53f93b9885a6b8754
This commit is contained in:
parent
1c7c304c88
commit
fb8a5145df
@ -21,6 +21,6 @@
|
|||||||
# NOTE(ianw): At 2018-12, ARA is only enabled during gate
|
# NOTE(ianw): At 2018-12, ARA is only enabled during gate
|
||||||
# testing jobs as we decide if or how to store data on
|
# testing jobs as we decide if or how to store data on
|
||||||
# production bridge.o.o
|
# production bridge.o.o
|
||||||
install_ansible_ara_name: '{{ bridge_ara_name | default("ara") }}'
|
install_ansible_ara_name: '{{ bridge_ara_name | default("ara[server]") }}'
|
||||||
install_ansible_ara_version: '{{ bridge_ara_version | default("0.16.4") }}'
|
install_ansible_ara_version: '{{ bridge_ara_version | default("latest") }}'
|
||||||
- root-keys
|
- root-keys
|
||||||
|
@ -44,7 +44,7 @@ Install and configure Ansible on a host via pip
|
|||||||
Whether or not to install the ARA Records Ansible callback plugin
|
Whether or not to install the ARA Records Ansible callback plugin
|
||||||
|
|
||||||
.. zuul:rolevar:: install_ansible_ara_name
|
.. zuul:rolevar:: install_ansible_ara_name
|
||||||
:default: ara
|
:default: ara[server]
|
||||||
|
|
||||||
The name of the ARA package to install. To install from
|
The name of the ARA package to install. To install from
|
||||||
alternative sources, this can be a URL for a remote package.
|
alternative sources, this can be a URL for a remote package.
|
||||||
@ -59,13 +59,17 @@ Install and configure Ansible on a host via pip
|
|||||||
package and hence the latest version is always installed.
|
package and hence the latest version is always installed.
|
||||||
|
|
||||||
.. zuul:rolevar:: install_ansible_ara_config
|
.. zuul:rolevar:: install_ansible_ara_config
|
||||||
:default: {"database": "sqlite:////var/cache/ansible/ara.sqlite"}
|
|
||||||
|
|
||||||
A dictionary of key-value pairs to be added to the ARA
|
A dictionary of configuration keys and their values for ARA's Ansible plugins.
|
||||||
configuration file
|
|
||||||
|
|
||||||
*database*: Connection string for the database (ex: mysql+pymysql://ara:password@localhost/ara)
|
Default configuration keys:
|
||||||
|
|
||||||
|
- ``api_client: offline`` (can be ``http`` for sending to remote API servers)
|
||||||
|
- ``api_server: http://127.0.0.1:8000`` (has no effect when using offline)
|
||||||
|
- ``api_username: null`` (if required, an API username)
|
||||||
|
- ``api_password: null`` (if required, an API password)
|
||||||
|
- ``api_timeout: 30`` (the timeout on http requests)
|
||||||
|
|
||||||
For a list of available configuration options, see the `ARA documentation`_
|
For a list of available configuration options, see the `ARA documentation`_
|
||||||
|
|
||||||
.. _ARA documentation: https://ara.readthedocs.io/en/stable/configuration.html
|
.. _ARA documentation: https://ara.readthedocs.io/en/latest/ara-plugin-configuration.html
|
||||||
|
@ -1,12 +1,11 @@
|
|||||||
# Whether or not to install ARA
|
# Whether or not to install ARA
|
||||||
install_ansible_ara_enable: false
|
install_ansible_ara_enable: false
|
||||||
|
|
||||||
# See available configuration options in the ARA docs:
|
# See available configuration options for the callback in the ARA docs:
|
||||||
# https://ara.readthedocs.io/en/stable/configuration.html
|
# https://ara.readthedocs.io/en/latest/ara-plugin-configuration.html
|
||||||
# Note that this may be set in the private host vars when using mysql so we can
|
|
||||||
# keep the credentials secret.
|
|
||||||
install_ansible_ara_config:
|
install_ansible_ara_config:
|
||||||
# Connection string for ARA
|
api_client: offline
|
||||||
# https://ara.readthedocs.io/en/stable/configuration.html#ara-database
|
# api_server: http://127.0.0.1:8000
|
||||||
# Ex: mysql+pymysql://ara:password@localhost/ara
|
# api_username: null
|
||||||
database: "sqlite:////var/cache/ansible/ara.sqlite"
|
# api_password: null
|
||||||
|
# api_timeout: 30
|
||||||
|
@ -1,9 +1,3 @@
|
|||||||
- name: Install pymysql for ara
|
|
||||||
pip:
|
|
||||||
name: pymysql
|
|
||||||
state: present
|
|
||||||
when: '"pymysql" in install_ansible_ara_config["database"]'
|
|
||||||
|
|
||||||
# If ansible_install_ansible_ara_version is not defined it should be "latest"
|
# If ansible_install_ansible_ara_version is not defined it should be "latest"
|
||||||
- name: Set ara default version to latest
|
- name: Set ara default version to latest
|
||||||
set_fact:
|
set_fact:
|
||||||
@ -27,7 +21,7 @@
|
|||||||
|
|
||||||
- name: Install ARA
|
- name: Install ARA
|
||||||
pip:
|
pip:
|
||||||
name: '{{ install_ansible_ara_name | default("ara") }}'
|
name: '{{ install_ansible_ara_name | default("ara[server]") }}'
|
||||||
version: '{{ _install_ansible_ara_version | default(omit) }}'
|
version: '{{ _install_ansible_ara_version | default(omit) }}'
|
||||||
state: '{{ _install_ansible_ara_state | default(omit) }}'
|
state: '{{ _install_ansible_ara_state | default(omit) }}'
|
||||||
|
|
||||||
|
@ -50,27 +50,18 @@
|
|||||||
recurse: yes
|
recurse: yes
|
||||||
become: yes
|
become: yes
|
||||||
|
|
||||||
- name: Ensure ARA log directories exist
|
- name: Generate ARA static report
|
||||||
file:
|
command: ara-manage generate /root/.ara/static
|
||||||
path: "{{ item }}"
|
become: yes
|
||||||
state: directory
|
|
||||||
with_items:
|
|
||||||
- "{{ ansible_user_dir }}/zuul-output/logs/ara-report"
|
|
||||||
|
|
||||||
- name: Copy ARA database into report dir
|
- name: Collect testing ARA results
|
||||||
copy:
|
synchronize:
|
||||||
remote_src: true
|
dest: "{{ log_dir }}/ara-report"
|
||||||
src: /var/cache/ansible/ara.sqlite
|
mode: pull
|
||||||
dest: "{{ ansible_user_dir }}/zuul-output/logs/ara-report/ara.sqlite"
|
src: "/root/.ara/static/"
|
||||||
|
verify_host: true
|
||||||
- name: Create ARA report
|
become: yes
|
||||||
include_role:
|
ignore_errors: true
|
||||||
name: ara-report
|
|
||||||
vars:
|
|
||||||
ara_database_path: "{{ ansible_user_dir }}/zuul-output/logs/ara-report/ara.sqlite"
|
|
||||||
ara_report_path: "{{ ansible_user_dir }}/zuul-output/logs/ara-report/"
|
|
||||||
ara_report_type: html
|
|
||||||
ara_report_artifact_prefix: 'bridge.openstack.org/'
|
|
||||||
|
|
||||||
- name: Collect ansible configuration
|
- name: Collect ansible configuration
|
||||||
synchronize:
|
synchronize:
|
||||||
|
@ -58,9 +58,9 @@ def test_root_authorized_keys(host):
|
|||||||
|
|
||||||
|
|
||||||
def test_ara(host):
|
def test_ara(host):
|
||||||
ara = host.run('ara playbook list')
|
ara = host.run('ara-manage migrate')
|
||||||
assert ara.rc == 0
|
assert ara.rc == 0
|
||||||
database = host.file('/var/cache/ansible/ara.sqlite')
|
database = host.file('/root/.ara/server/ansible.sqlite')
|
||||||
assert database.exists
|
assert database.exists
|
||||||
|
|
||||||
|
|
||||||
|
@ -80,10 +80,6 @@
|
|||||||
override-checkout: devel
|
override-checkout: devel
|
||||||
- name: github.com/pytest-dev/pytest-testinfra
|
- name: github.com/pytest-dev/pytest-testinfra
|
||||||
- name: openstack/openstacksdk
|
- name: openstack/openstacksdk
|
||||||
- name: recordsansible/ara
|
|
||||||
# NOTE(ianw): 2019-06-11 pinned to stable branch until we handle 1.0
|
|
||||||
# http://lists.openstack.org/pipermail/openstack-infra/2019-June/006400.html
|
|
||||||
override-checkout: stable/0.x
|
|
||||||
- name: github.com/ansible-collections/ansible.posix
|
- name: github.com/ansible-collections/ansible.posix
|
||||||
override-checkout: main
|
override-checkout: main
|
||||||
- name: github.com/ansible-collections/ansible.netcommon
|
- name: github.com/ansible-collections/ansible.netcommon
|
||||||
@ -92,12 +88,13 @@
|
|||||||
override-checkout: main
|
override-checkout: main
|
||||||
- name: github.com/ansible-collections/community.general
|
- name: github.com/ansible-collections/community.general
|
||||||
override-checkout: main
|
override-checkout: main
|
||||||
|
- name: github.com/ansible-community/ara
|
||||||
vars:
|
vars:
|
||||||
bridge_ansible_name: '{{ ansible_user_dir}}/src/github.com/ansible/ansible'
|
bridge_ansible_name: '{{ ansible_user_dir}}/src/github.com/ansible/ansible'
|
||||||
bridge_ansible_version: null
|
bridge_ansible_version: null
|
||||||
bridge_openstacksdk_name: '{{ ansible_user_dir }}/src/opendev.org/openstack/openstacksdk'
|
bridge_openstacksdk_name: '{{ ansible_user_dir }}/src/opendev.org/openstack/openstacksdk'
|
||||||
bridge_openstacksdk_version: null
|
bridge_openstacksdk_version: null
|
||||||
bridge_ara_name: '{{ ansible_user_dir}}/src/opendev.org/recordsansible/ara'
|
bridge_ara_name: '{{ ansible_user_dir}}/src/github.com/ansible-community/ara[server]'
|
||||||
bridge_ara_version: null
|
bridge_ara_version: null
|
||||||
|
|
||||||
# Although we don't have an arm64 based bridge; Zuul can't currently
|
# Although we don't have an arm64 based bridge; Zuul can't currently
|
||||||
|
Loading…
Reference in New Issue
Block a user