From 510a7e8a96917955607ca3769c8e4f5bbca41019 Mon Sep 17 00:00:00 2001 From: "James E. Blair" Date: Mon, 17 Jul 2017 13:45:12 -0700 Subject: [PATCH] Add sample base job Based on current openstack base job. This isn't the entire job yet as we cannot parameterize everything, but it's a start. Change-Id: I8315dadef3923d68de80df867e05f16b2cbda3a1 --- playbooks/base/post-ssh.yaml | 3 +++ playbooks/base/pre.yaml | 8 ++++++++ zuul.yaml | 24 ++++++++++++++++++++++++ 3 files changed, 35 insertions(+) create mode 100644 playbooks/base/post-ssh.yaml create mode 100644 playbooks/base/pre.yaml diff --git a/playbooks/base/post-ssh.yaml b/playbooks/base/post-ssh.yaml new file mode 100644 index 000000000..d793838ce --- /dev/null +++ b/playbooks/base/post-ssh.yaml @@ -0,0 +1,3 @@ +- hosts: all + roles: + - remove-build-sshkey diff --git a/playbooks/base/pre.yaml b/playbooks/base/pre.yaml new file mode 100644 index 000000000..320c179df --- /dev/null +++ b/playbooks/base/pre.yaml @@ -0,0 +1,8 @@ +- hosts: all + roles: + - add-build-sshkey + - prepare-workspace + - role: validate-host + # TODO(mordred) When we have site-local variables, these should go there + zuul_traceroute_host: git.openstack.org + zuul_image_manifest: /etc/dib-builddate.txt diff --git a/zuul.yaml b/zuul.yaml index 39f5632a2..2c28cdbed 100644 --- a/zuul.yaml +++ b/zuul.yaml @@ -1,3 +1,27 @@ +# TODO: further parameterize the base job and roles so that it can +# include log publishing and nodeset defaults once Zuul supports +# site-local variables. +- job: + name: base + description: | + A sample base job. + + Zuul installations should override this job using the project + "shadow" functionality. + + All jobs ultimately inherit from this. It runs a pre-playbook + which copies all of the job's prepared git repos on to all of + the nodes in the nodeset and sets the default timeout value. + + Zuul installations should add a log publishing post playbook to + this job, and may wish to supply a default nodeset and adjust + the timeout values. + pre-run: playbooks/base/pre + post-run: playbooks/base/post-ssh + roles: + - zuul: openstack-infra/zuul-jobs + timeout: 1800 + - job: name: unittests parent: base