From 0beba1db12f29fb33e2fac5de8e1ace5d9b63419 Mon Sep 17 00:00:00 2001 From: ghanshyam Date: Fri, 11 Jan 2019 11:46:23 +0000 Subject: [PATCH] Fix queens py35 job Current job of queens py35 try to override the stable/queens branch using override_branch var which is zuulv3 var not legacy zuul job. On legacy zuul job, branch can be overridden by BRANCH_OVERRIDE var. This is problem in all stable branch job running on congress-tempest-plugin master gate. Other stable branch job somehow not failing and master version of all repo are working fine there but they do not actually test stable branch. queens py35 job is failing when using master version of other repo. Plan is to migrate thw congress jobs to zuulv3 which will be easy to fix and use override_branch for all stable branch jobs running on master. But this can take time so let's fix broken job only as of now. This commit fixes this job only to unblock the gate. Change-Id: I328cf0330a054e76e8ac7895a2f844fdb7ab4226 --- .zuul.yaml | 3 +- .../post.yaml | 80 +++++++++++++++++ .../run.yaml | 88 +++++++++++++++++++ 3 files changed, 170 insertions(+), 1 deletion(-) create mode 100644 playbooks/legacy/congress-devstack-py35-api-mysql-queens/post.yaml create mode 100644 playbooks/legacy/congress-devstack-py35-api-mysql-queens/run.yaml diff --git a/.zuul.yaml b/.zuul.yaml index bbef984..c290ee7 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -26,7 +26,8 @@ - job: name: congress-devstack-py35-api-mysql-queens parent: congress-devstack-py35-api-mysql - override-checkout: stable/queens + run: playbooks/legacy/congress-devstack-py35-api-mysql-queens/run.yaml + post-run: playbooks/legacy/congress-devstack-py35-api-mysql-queens/post.yaml - project: templates: diff --git a/playbooks/legacy/congress-devstack-py35-api-mysql-queens/post.yaml b/playbooks/legacy/congress-devstack-py35-api-mysql-queens/post.yaml new file mode 100644 index 0000000..dac8753 --- /dev/null +++ b/playbooks/legacy/congress-devstack-py35-api-mysql-queens/post.yaml @@ -0,0 +1,80 @@ +- hosts: primary + tasks: + + - name: Copy files from {{ ansible_user_dir }}/workspace/ on node + synchronize: + src: '{{ ansible_user_dir }}/workspace/' + dest: '{{ zuul.executor.log_root }}' + mode: pull + copy_links: true + verify_host: true + rsync_opts: + - --include=**/*nose_results.html + - --include=*/ + - --exclude=* + - --prune-empty-dirs + + - name: Copy files from {{ ansible_user_dir }}/workspace/ on node + synchronize: + src: '{{ ansible_user_dir }}/workspace/' + dest: '{{ zuul.executor.log_root }}' + mode: pull + copy_links: true + verify_host: true + rsync_opts: + - --include=**/*testr_results.html.gz + - --include=*/ + - --exclude=* + - --prune-empty-dirs + + - name: Copy files from {{ ansible_user_dir }}/workspace/ on node + synchronize: + src: '{{ ansible_user_dir }}/workspace/' + dest: '{{ zuul.executor.log_root }}' + mode: pull + copy_links: true + verify_host: true + rsync_opts: + - --include=/.testrepository/tmp* + - --include=*/ + - --exclude=* + - --prune-empty-dirs + + - name: Copy files from {{ ansible_user_dir }}/workspace/ on node + synchronize: + src: '{{ ansible_user_dir }}/workspace/' + dest: '{{ zuul.executor.log_root }}' + mode: pull + copy_links: true + verify_host: true + rsync_opts: + - --include=**/*testrepository.subunit.gz + - --include=*/ + - --exclude=* + - --prune-empty-dirs + + - name: Copy files from {{ ansible_user_dir }}/workspace/ on node + synchronize: + src: '{{ ansible_user_dir }}/workspace/' + dest: '{{ zuul.executor.log_root }}/tox' + mode: pull + copy_links: true + verify_host: true + rsync_opts: + - --include=/.tox/*/log/* + - --include=*/ + - --exclude=* + - --prune-empty-dirs + + - name: Copy files from {{ ansible_user_dir }}/workspace/ on node + synchronize: + src: '{{ ansible_user_dir }}/workspace/' + dest: '{{ zuul.executor.log_root }}' + mode: pull + copy_links: true + verify_host: true + rsync_opts: + - --include=/logs/** + - --include=*/ + - --exclude=* + - --prune-empty-dirs diff --git a/playbooks/legacy/congress-devstack-py35-api-mysql-queens/run.yaml b/playbooks/legacy/congress-devstack-py35-api-mysql-queens/run.yaml new file mode 100644 index 0000000..fd1b763 --- /dev/null +++ b/playbooks/legacy/congress-devstack-py35-api-mysql-queens/run.yaml @@ -0,0 +1,88 @@ +- hosts: all + name: Autoconverted job legacy-congress-dsvm-py35-api-mysql from old job gate-congress-dsvm-py35-api-mysql-ubuntu-xenial-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-infra/devstack-gate + dest: devstack-gate + EOF + /usr/zuul-env/bin/zuul-cloner -m clonemap.yaml --cache-dir /opt/git \ + git://git.openstack.org \ + openstack-infra/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]] + # swift is not ready for python3 yet + disable_service s-account + disable_service s-container + disable_service s-object + disable_service s-proxy + # without Swift, c-bak cannot run (in the Gate at least) + disable_service c-bak + # aodh not ready for python3 yet + # enable_plugin aodh git://git.openstack.org/openstack/aodh + enable_plugin heat git://git.openstack.org/openstack/heat + enable_plugin congress git://git.openstack.org/openstack/congress + enable_plugin murano git://git.openstack.org/openstack/murano + enable_plugin neutron https://git.openstack.org/openstack/neutron + # To deploy congress as multi-process (api, pe, datasources) + CONGRESS_MULTIPROCESS_DEPLOYMENT=True + CONGRESS_EXPOSE_ENCRYPTION_KEY_FOR_TEST=True + ENABLE_CONGRESS_Z3=True + USE_Z3_RELEASE=4.7.1 + TEMPEST_PLUGINS='/opt/stack/new/congress-tempest-plugin /opt/stack/new/murano-tempest-plugin /opt/stack/new/heat-tempest-plugin' + EOF + executable: /bin/bash + chdir: '{{ ansible_user_dir }}/workspace' + environment: '{{ zuul | zuul_legacy_vars }}' + + - shell: + cmd: | + set -e + set -x + export DEVSTACK_GATE_USE_PYTHON3=True + # swift is not ready for python3 yet + # ENABLED_SERVICES=s-proxy,s-object,s-container,s-account, + ENABLED_SERVICES+=neutron-qos + export PYTHONUNBUFFERED=true + export DEVSTACK_GATE_TEMPEST=1 + export DEVSTACK_GATE_TEMPEST_REGEX="congress_tempest_plugin" + export DEVSTACK_GATE_NEUTRON=1 + export PROJECTS="openstack/congress $PROJECTS" + export PROJECTS="openstack/congress-dashboard $PROJECTS" + export PROJECTS="openstack/python-congressclient $PROJECTS" + export PROJECTS="openstack/congress-tempest-plugin $PROJECTS" + export PROJECTS="openstack/murano $PROJECTS" + export PROJECTS="openstack/murano-dashboard $PROJECTS" + export PROJECTS="openstack/python-muranoclient $PROJECTS" + export PROJECTS="openstack/murano-tempest-plugin $PROJECTS" + export PROJECTS="openstack/heat-tempest-plugin $PROJECTS" + + export ENABLED_SERVICES + export BRANCH_OVERRIDE=stable/queens + if [ "$BRANCH_OVERRIDE" != "default" ] ; then + export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE + fi + + 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 }}'