diff --git a/.zuul.yaml b/.zuul.yaml new file mode 100644 index 0000000..b8f81f3 --- /dev/null +++ b/.zuul.yaml @@ -0,0 +1,16 @@ +- job: + name: gceapi-functional-neutron + parent: legacy-dsvm-base + run: playbooks/functional-neutron-dsvm-gceapi/run.yaml + post-run: playbooks/functional-neutron-dsvm-gceapi/post.yaml + timeout: 7500 + required-projects: + - openstack-infra/devstack-gate + - openstack/gce-api + - openstack/neutron + +- project: + check: + jobs: + - gceapi-functional-neutron: + voting: false diff --git a/playbooks/functional-neutron-dsvm-gceapi/post.yaml b/playbooks/functional-neutron-dsvm-gceapi/post.yaml new file mode 100644 index 0000000..e07f551 --- /dev/null +++ b/playbooks/functional-neutron-dsvm-gceapi/post.yaml @@ -0,0 +1,15 @@ +- 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=/logs/** + - --include=*/ + - --exclude=* + - --prune-empty-dirs diff --git a/playbooks/functional-neutron-dsvm-gceapi/run.yaml b/playbooks/functional-neutron-dsvm-gceapi/run.yaml new file mode 100644 index 0000000..f6d0405 --- /dev/null +++ b/playbooks/functional-neutron-dsvm-gceapi/run.yaml @@ -0,0 +1,69 @@ +- hosts: all + name: Autoconverted job legacy-functional-neutron-dsvm-gceapi from old job gate-functional-neutron-dsvm-gceapi-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]] + enable_plugin gce-api git://git.openstack.org/openstack/gce-api + + 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 DEVSTACK_GATE_TEMPEST_NOTESTS=1 + export BRANCH_OVERRIDE=default + if [ "$BRANCH_OVERRIDE" != "default" ] ; then + export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE + fi + export PROJECTS="openstack/gce-api $PROJECTS" + + if [ "neutron" = "neutron" ] ; then + export DEVSTACK_GATE_NEUTRON=1 + else + export DEVSTACK_GATE_NEUTRON=0 + fi + + function post_test_hook { + source $BASE/new/devstack/accrc/admin/admin + cd /opt/stack/new/gce-api/ + ./gceapi/tests/contrib/post_test_hook.sh + } + 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 }}'