
This commit was bulk generated and pushed by the OpenDev sysadmins as a part of the Git hosting and code review systems migration detailed in these mailing list posts: http://lists.openstack.org/pipermail/openstack-discuss/2019-March/003603.html http://lists.openstack.org/pipermail/openstack-discuss/2019-April/004920.html Attempts have been made to correct repository namespaces and hostnames based on simple pattern matching, but it's possible some were updated incorrectly or missed entirely. Please reach out to us via the contact information listed at https://opendev.org/ with any questions you may have.
76 lines
2.6 KiB
YAML
76 lines
2.6 KiB
YAML
- hosts: all
|
|
name: Autoconverted job legacy-dsvm-os-loganalyze from old job gate-dsvm-os-loganalyze-nv
|
|
tasks:
|
|
|
|
- name: Ensure legacy workspace directory
|
|
file:
|
|
path: '{{ ansible_user_dir }}/workspace'
|
|
state: directory
|
|
|
|
- shell:
|
|
cmd: |
|
|
set -e
|
|
set -x
|
|
cat > clonemap.yaml << EOF
|
|
clonemap:
|
|
- name: openstack/devstack-gate
|
|
dest: devstack-gate
|
|
EOF
|
|
/usr/zuul-env/bin/zuul-cloner -m clonemap.yaml --cache-dir /opt/git \
|
|
https://opendev.org \
|
|
openstack/devstack-gate
|
|
executable: /bin/bash
|
|
chdir: '{{ ansible_user_dir }}/workspace'
|
|
environment: '{{ zuul | zuul_legacy_vars }}'
|
|
|
|
- shell:
|
|
cmd: |
|
|
set -e
|
|
set -x
|
|
cat << 'EOF' >>"/tmp/dg-local.conf"
|
|
[[local|localrc]]
|
|
enable_plugin devstack-plugin-os-loganalyze https://opendev.org/openstack/os-loganalyze
|
|
|
|
EOF
|
|
executable: /bin/bash
|
|
chdir: '{{ ansible_user_dir }}/workspace'
|
|
environment: '{{ zuul | zuul_legacy_vars }}'
|
|
|
|
- shell:
|
|
cmd: |
|
|
set -e
|
|
set -x
|
|
export PYTHONUNBUFFERED=true
|
|
export DEVSTACK_GATE_TEMPEST=1
|
|
export ENABLED_SERVICES=os-loganalyze
|
|
export PROJECTS="openstack/os-loganalyze $PROJECTS"
|
|
|
|
function post_test_hook {
|
|
# Copy the tempest output to the os-loganalyze DocumentRoot
|
|
sudo cp -r logs/* /var/www/logs/
|
|
# Grab normally marked up file
|
|
wget --header="Accept: text/html" http://localhost:8080/tempest.txt.gz
|
|
# Check display level options are available
|
|
if ! grep -q "<span id='selector'>" tempest.txt.gz; then
|
|
return 1
|
|
fi
|
|
if ! grep -q "<a href='?level=DEBUG'>DEBUG</a> |" tempest.txt.gz; then
|
|
return 1
|
|
fi
|
|
# Check when fetching as plain, options are missing
|
|
wget http://localhost:8080/tempest.txt.gz
|
|
if grep -q "<span id='selector'>" tempest.txt.gz; then
|
|
return 1
|
|
fi
|
|
if grep -q "<a href='?level=DEBUG'>DEBUG</a> |" tempest.txt.gz; then
|
|
return 1
|
|
fi
|
|
}
|
|
export -f post_test_hook
|
|
|
|
cp devstack-gate/devstack-vm-gate-wrap.sh ./safe-devstack-vm-gate-wrap.sh
|
|
./safe-devstack-vm-gate-wrap.sh
|
|
executable: /bin/bash
|
|
chdir: '{{ ansible_user_dir }}/workspace'
|
|
environment: '{{ zuul | zuul_legacy_vars }}'
|