diff options
author | Tim Burke <tim.burke@gmail.com> | 2018-08-06 19:25:36 +0000 |
---|---|---|
committer | Andreas Jaeger <aj@suse.com> | 2018-09-08 17:39:54 +0200 |
commit | 3aff40b0bf6fc63a9185ee349d5e195b1198959a (patch) | |
tree | 76b8c26a6021bb08a7014418d35fbfa80654eb1d | |
parent | 965bf11b07266f324f4362ae19fadd691ce576b8 (diff) | |
download | swift-3aff40b0bf6fc63a9185ee349d5e195b1198959a.tar.gz |
Move legacy-swift-dsvm-functional job in-tree
Import legacy jobs since devstack does not have Zuul v3 native jobs
for ocata defined.
Co-Authored-By: Andreas Jaeger <jaegerandi@gmail.com>
Change-Id: I49d963b98f3df21fea0db24c83553ef873ad73c8
-rw-r--r-- | .zuul.yaml | 26 | ||||
-rw-r--r-- | tools/playbooks/swift-dsvm-functional-identity-v3-only/post.yaml | 15 | ||||
-rw-r--r-- | tools/playbooks/swift-dsvm-functional-identity-v3-only/run.yaml | 63 | ||||
-rw-r--r-- | tools/playbooks/swift-dsvm-functional/post.yaml | 15 | ||||
-rw-r--r-- | tools/playbooks/swift-dsvm-functional/run.yaml | 62 |
5 files changed, 178 insertions, 3 deletions
diff --git a/.zuul.yaml b/.zuul.yaml index e6813b117..4f71f41ce 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -1,3 +1,23 @@ +- job: + name: swift-dsvm-functional + parent: legacy-dsvm-base + run: tools/playbooks/swift-dsvm-functional/run.yaml + post-run: tools/playbooks/swift-dsvm-functional/post.yaml + timeout: 6000 + required-projects: + - openstack-infra/devstack-gate + - openstack/swift + +- job: + name: swift-dsvm-functional-identity-v3-only + parent: legacy-dsvm-base + run: tools/playbooks/swift-dsvm-functional-identity-v3-only/run.yaml + post-run: tools/playbooks/swift-dsvm-functional-identity-v3-only/post.yaml + timeout: 6000 + required-projects: + - openstack-infra/devstack-gate + - openstack/swift + - project: templates: - publish-openstack-sphinx-docs @@ -7,14 +27,14 @@ check: jobs: - openstack-tox-pep8 - - legacy-swift-dsvm-functional: + - swift-dsvm-functional: irrelevant-files: - ^api-ref/.*$ - ^doc/.*$ - ^install-guide/.*$ - ^releasenotes/.*$ - ^test/unit/.*$ - - legacy-swift-dsvm-functional-identity-v3-only: + - swift-dsvm-functional-identity-v3-only: voting: false irrelevant-files: - ^api-ref/.*$ @@ -43,7 +63,7 @@ gate: jobs: - openstack-tox-pep8 - - legacy-swift-dsvm-functional: + - swift-dsvm-functional: irrelevant-files: - ^api-ref/.*$ - ^doc/.*$ diff --git a/tools/playbooks/swift-dsvm-functional-identity-v3-only/post.yaml b/tools/playbooks/swift-dsvm-functional-identity-v3-only/post.yaml new file mode 100644 index 000000000..e07f5510a --- /dev/null +++ b/tools/playbooks/swift-dsvm-functional-identity-v3-only/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/tools/playbooks/swift-dsvm-functional-identity-v3-only/run.yaml b/tools/playbooks/swift-dsvm-functional-identity-v3-only/run.yaml new file mode 100644 index 000000000..972a6410f --- /dev/null +++ b/tools/playbooks/swift-dsvm-functional-identity-v3-only/run.yaml @@ -0,0 +1,63 @@ +- hosts: all + name: Autoconverted job legacy-swift-dsvm-functional-identity-v3-only from old job + gate-swift-dsvm-functional-identity-v3-only-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 + export PYTHONUNBUFFERED=true + export FUNCTEST_TIMEOUT=30 + # Disable all services + export DEVSTACK_GATE_NO_SERVICES=1 + # Add only what we want, keystone + swift + export DEVSTACK_GATE_SWIFT=1 + export DEVSTACK_GATE_KEYSTONE=1 + # Need to override default which is neutron enabled + export DEVSTACK_GATE_NEUTRON=0 + export DEVSTACK_GATE_TEMPEST=0 + export DEVSTACK_GATE_EXERCISES=0 + export DEVSTACK_GATE_INSTALL_TESTONLY=1 + export BRANCH_OVERRIDE=default + if [ "$BRANCH_OVERRIDE" != "default" ] ; then + export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE + fi + if [ "-identity-v3-only" == "-identity-v3-only" ] ; then + export DEVSTACK_LOCAL_CONFIG="ENABLE_IDENTITY_V2=False" + fi + + function post_test_hook { + cd /opt/stack/new/swift + # Launch V2 auth tests and v1 tests after. + sudo -H -u stack timeout -s 9 ${FUNCTEST_TIMEOUT}m tox -e func && \ + sudo -H -u stack SWIFT_TEST_CONFIG_FILE=/opt/stack/new/swift/test/sample.conf \ + timeout -s 9 ${FUNCTEST_TIMEOUT}m tox -e func + } + 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 }}' diff --git a/tools/playbooks/swift-dsvm-functional/post.yaml b/tools/playbooks/swift-dsvm-functional/post.yaml new file mode 100644 index 000000000..e07f5510a --- /dev/null +++ b/tools/playbooks/swift-dsvm-functional/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/tools/playbooks/swift-dsvm-functional/run.yaml b/tools/playbooks/swift-dsvm-functional/run.yaml new file mode 100644 index 000000000..b78c51caf --- /dev/null +++ b/tools/playbooks/swift-dsvm-functional/run.yaml @@ -0,0 +1,62 @@ +- hosts: all + name: Autoconverted job legacy-swift-dsvm-functional from old job gate-swift-dsvm-functional-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 + export PYTHONUNBUFFERED=true + export FUNCTEST_TIMEOUT=30 + # Disable all services + export DEVSTACK_GATE_NO_SERVICES=1 + # Add only what we want, keystone + swift + export DEVSTACK_GATE_SWIFT=1 + export DEVSTACK_GATE_KEYSTONE=1 + # Need to override default which is neutron enabled + export DEVSTACK_GATE_NEUTRON=0 + export DEVSTACK_GATE_TEMPEST=0 + export DEVSTACK_GATE_EXERCISES=0 + export DEVSTACK_GATE_INSTALL_TESTONLY=1 + export BRANCH_OVERRIDE=default + if [ "$BRANCH_OVERRIDE" != "default" ] ; then + export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE + fi + if [ "" == "-identity-v3-only" ] ; then + export DEVSTACK_LOCAL_CONFIG="ENABLE_IDENTITY_V2=False" + fi + + function post_test_hook { + cd /opt/stack/new/swift + # Launch V2 auth tests and v1 tests after. + sudo -H -u stack timeout -s 9 ${FUNCTEST_TIMEOUT}m tox -e func && \ + sudo -H -u stack SWIFT_TEST_CONFIG_FILE=/opt/stack/new/swift/test/sample.conf \ + timeout -s 9 ${FUNCTEST_TIMEOUT}m tox -e func + } + 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 }}' |