summaryrefslogtreecommitdiff
path: root/playbooks
diff options
context:
space:
mode:
authorNguyen Phuong An <AnNP@vn.fujitsu.com>2018-07-04 13:05:27 +0700
committerNguyen Phuong An <AnNP@vn.fujitsu.com>2018-07-30 09:46:52 +0700
commitb79021378835426acbf9e0e75f6468f825d84b8b (patch)
tree25ea17ff4e64c932badbafd05e84e3891cc3c466 /playbooks
parentd00a1558a5a51ad8d189ad3d72aabae6447a88b5 (diff)
downloadneutron-b79021378835426acbf9e0e75f6468f825d84b8b.tar.gz
WSGI: Add experimental jobs with uwsgi
This patch adds exprimental tempest, functional and fullstack jobs when neutron-api is served by a webserver as a part of community goal. Change-Id: Id88ca1a6997d39bf0d14589c0a2725b4ac109cec
Diffstat (limited to 'playbooks')
-rw-r--r--playbooks/legacy/neutron-fullstack-with-uwsgi/post.yaml80
-rw-r--r--playbooks/legacy/neutron-fullstack-with-uwsgi/run.yaml67
-rw-r--r--playbooks/legacy/neutron-functional-with-uwsgi/post.yaml80
-rw-r--r--playbooks/legacy/neutron-functional-with-uwsgi/run.yaml67
4 files changed, 294 insertions, 0 deletions
diff --git a/playbooks/legacy/neutron-fullstack-with-uwsgi/post.yaml b/playbooks/legacy/neutron-fullstack-with-uwsgi/post.yaml
new file mode 100644
index 0000000000..dac875340a
--- /dev/null
+++ b/playbooks/legacy/neutron-fullstack-with-uwsgi/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/neutron-fullstack-with-uwsgi/run.yaml b/playbooks/legacy/neutron-fullstack-with-uwsgi/run.yaml
new file mode 100644
index 0000000000..2e0926c00d
--- /dev/null
+++ b/playbooks/legacy/neutron-fullstack-with-uwsgi/run.yaml
@@ -0,0 +1,67 @@
+- hosts: all
+ name: This is a Neutron Fullstack test suite running with uwsgi
+ 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]]
+ NEUTRON_DEPLOY_MOD_WSGI=True
+
+ 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=0
+ export DEVSTACK_GATE_EXERCISES=0
+ export DEVSTACK_GATE_NEUTRON=1
+ export DEVSTACK_GATE_INSTALL_TESTONLY=1
+ export BRANCH_OVERRIDE=default
+ if [ "$BRANCH_OVERRIDE" != "default" ] ; then
+ export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE
+ fi
+
+ function gate_hook {
+ bash -xe $BASE/new/neutron/neutron/tests/contrib/gate_hook.sh dsvm-fullstack
+ }
+ export -f gate_hook
+
+ function post_test_hook {
+ bash -xe $BASE/new/neutron/neutron/tests/contrib/post_test_hook.sh dsvm-fullstack
+ }
+ 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/playbooks/legacy/neutron-functional-with-uwsgi/post.yaml b/playbooks/legacy/neutron-functional-with-uwsgi/post.yaml
new file mode 100644
index 0000000000..dac875340a
--- /dev/null
+++ b/playbooks/legacy/neutron-functional-with-uwsgi/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/neutron-functional-with-uwsgi/run.yaml b/playbooks/legacy/neutron-functional-with-uwsgi/run.yaml
new file mode 100644
index 0000000000..048d684ea9
--- /dev/null
+++ b/playbooks/legacy/neutron-functional-with-uwsgi/run.yaml
@@ -0,0 +1,67 @@
+- hosts: all
+ name: This is a Neutron Functional test suite running with uwsgi
+ 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]]
+ NEUTRON_DEPLOY_MOD_WSGI=True
+
+ 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=0
+ export DEVSTACK_GATE_EXERCISES=0
+ export DEVSTACK_GATE_NEUTRON=1
+ export DEVSTACK_GATE_INSTALL_TESTONLY=1
+ export BRANCH_OVERRIDE=default
+ if [ "$BRANCH_OVERRIDE" != "default" ] ; then
+ export OVERRIDE_ZUUL_BRANCH=$BRANCH_OVERRIDE
+ fi
+
+ function gate_hook {
+ bash -xe $BASE/new/neutron/neutron/tests/contrib/gate_hook.sh dsvm-functional
+ }
+ export -f gate_hook
+
+ function post_test_hook {
+ bash -xe $BASE/new/neutron/neutron/tests/contrib/post_test_hook.sh dsvm-functional
+ }
+ 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 }}'