Add zuul node

Here is our first example node using zuul.  Currently, we simply
install zuul with no additional configuration.

Change-Id: I718007fb507013895844fcf2caf6de7219f09c70
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
Paul Belanger 2016-02-01 13:20:02 -05:00
parent eb102b286d
commit 0348996108
5 changed files with 69 additions and 4 deletions

18
tox.ini
View File

@ -8,11 +8,21 @@ deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
[testenv:ansible-lint]
setenv =
ANSIBLE_CONFIG = tests/ansible.cfg
whitelist_externals = bash
# NOTE(pabelanger): Place holder until we add ansible playbooks
commands = /bin/true
commands =
bash -c "find . -type f -regex '.*.y[a]?ml' -print0 | xargs -t -n1 -0 \
ansible-lint"
[testenv:deploy]
commands =
{toxinidir}/tools/install_roles.sh
ansible-playbook -i windmill/inventory windmill/site.yaml {posargs}
passenv =
HOME
SSH_AUTH_SOCK
setenv =
ANSIBLE_CONFIG = {toxinidir}/windmill/ansible.cfg
PYTHONUNBUFFERED = 1
[testenv:docs]
commands = python setup.py build_sphinx

2
windmill/inventory Normal file
View File

@ -0,0 +1,2 @@
[zuul]
zuul ansible_host=localhost ansible_user=jenkins

15
windmill/site.yaml Normal file
View File

@ -0,0 +1,15 @@
# Copyright 2016 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
---
- include: zuul.yaml

16
windmill/vars/zuul.yaml Normal file
View File

@ -0,0 +1,16 @@
# Copyright 2016 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
---
# NOTE(pabelanger): This file _should_ be encrypted using ansible-vault. We
# current don't because this deployment is used as an example.

22
windmill/zuul.yaml Normal file
View File

@ -0,0 +1,22 @@
# Copyright 2016 Red Hat, Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
---
- name: Install zuul.
hosts: zuul
roles:
- windmill.zuul
vars_files:
- vars/zuul.yaml