From c37b27b8d03b941c99c060702858ba67935cbfa6 Mon Sep 17 00:00:00 2001 From: Sirajudeen Date: Fri, 12 Jun 2020 07:49:34 -0500 Subject: [PATCH] Zuul Job with Bash oriented gate tests * Added bash scripts in place of ansible playbooks/roles * zuul will run bash scripts, and this means that they are actually tested which will make development experience easier Change-Id: I60d1dac589ae8ad835d3f1dda5e2a45523367496 Relates-To: #222 --- tools/validate_docs | 2 +- zuul.d/jobs.yaml | 56 ++++++++++++++++++++++++++++++++++++++++++-- zuul.d/projects.yaml | 2 ++ 3 files changed, 57 insertions(+), 3 deletions(-) diff --git a/tools/validate_docs b/tools/validate_docs index 1bddde295..167a520c5 100755 --- a/tools/validate_docs +++ b/tools/validate_docs @@ -14,7 +14,7 @@ # The makefile entrypoint driver for document validation # Expected to be run from the project root -set -e +set -xe # get kind echo "Fetching kind from ${KIND_URL}..." diff --git a/zuul.d/jobs.yaml b/zuul.d/jobs.yaml index 7a783a911..c4bd95faf 100644 --- a/zuul.d/jobs.yaml +++ b/zuul.d/jobs.yaml @@ -49,8 +49,13 @@ name: airship-airshipctl-validate-site-docs pre-run: - playbooks/airship-airshipctl-deploy-docker.yaml - run: playbooks/airship-airshipctl-validate-documents.yaml + run: playbooks/airshipctl-gate-runner.yaml nodeset: airship-airshipctl-single-node + vars: + gate_scripts: + - ./tools/deployment/01_install_kubectl.sh + - ./tools/deployment/21_systemwide_executable.sh + - ./tools/validate_docs # TODO (dukov) remove this once phases framework is fully implemented voting: false @@ -72,7 +77,6 @@ pass-to-parent: true - job: - voting: true name: airship-airshipctl-gate-test attempts: 1 timeout: 3600 @@ -99,6 +103,7 @@ - airshipctl-phase-controlplane serve_dir: /srv/iso serve_port: 8099 + voting: true - job: name: airship-airshipctl-32GB-gate-test @@ -127,6 +132,53 @@ serve_port: 8099 voting: false +- job: + name: airship-airshipctl-gate-script-runner-test + attempts: 1 + timeout: 3600 + pre-run: + - playbooks/airship-airshipctl-deploy-docker.yaml + - playbooks/airship-airshipctl-build-gate.yaml + post-run: playbooks/airship-collect-logs.yaml + run: playbooks/airshipctl-gate-runner.yaml + nodeset: airship-airshipctl-single-16GB-bionic-node + vars: + site_name: test-site + gate_scripts: + - ./tools/deployment/01_install_kubectl.sh + - ./tools/deployment/21_systemwide_executable.sh + - ./tools/deployment/22_test_configs.sh + - ./tools/deployment/24_build_ephemeral_iso.sh + - ./tools/deployment/25_deploy_ephemeral_node.sh + - ./tools/deployment/26_deploy_metal3_capi_ephemeral_node.sh + - ./tools/deployment/30_deploy_controlplane.sh + serve_dir: /srv/iso + serve_port: 8099 + voting: false + +- job: + name: airship-airshipctl-32GB-gate-script-runner-test + nodeset: airship-airshipctl-single-32GB-bionic-node + pre-run: + - playbooks/airship-airshipctl-deploy-docker.yaml + - playbooks/airship-airshipctl-build-gate.yaml + post-run: playbooks/airship-collect-logs.yaml + run: playbooks/airshipctl-gate-runner.yaml + timeout: 3600 + vars: + site_name: test-site + gate_scripts: + - ./tools/deployment/01_install_kubectl.sh + - ./tools/deployment/21_systemwide_executable.sh + - ./tools/deployment/22_test_configs.sh + - ./tools/deployment/24_build_ephemeral_iso.sh + - ./tools/deployment/25_deploy_ephemeral_node.sh + - ./tools/deployment/26_deploy_metal3_capi_ephemeral_node.sh + - ./tools/deployment/30_deploy_controlplane.sh + serve_dir: /srv/iso + serve_port: 8099 + voting: false + - job: name: airship-airshipctl-publish-image parent: airship-airshipctl-build-image diff --git a/zuul.d/projects.yaml b/zuul.d/projects.yaml index 28ca39733..d30c4d9e0 100644 --- a/zuul.d/projects.yaml +++ b/zuul.d/projects.yaml @@ -26,6 +26,8 @@ # - airship-airshipctl-functional-existing-k8s TODO: Enable this when functional tests exist, and a cluster is up - airship-airshipctl-gate-test - airship-airshipctl-32GB-gate-test + - airship-airshipctl-gate-script-runner-test + - airship-airshipctl-32GB-gate-script-runner-test gate: jobs: - openstack-tox-docs