Add zuulv3 jobs support
Now that zuulv3 is live, we can switch to native ansible jobs. Change-Id: Idb7b57149def695c73f3d22e6500507e66e9189d Signed-off-by: Paul Belanger <pabelanger@redhat.com>
This commit is contained in:
parent
63c794fddb
commit
1842d7bed4
40
.zuul.yaml
Normal file
40
.zuul.yaml
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
- job:
|
||||||
|
name: ansible-role-diskimage-builder
|
||||||
|
run: tests/test.yaml
|
||||||
|
required-projects:
|
||||||
|
- name: openstack/diskimage-builder
|
||||||
|
roles:
|
||||||
|
- zuul: openstack/ansible-role-diskimage-builder
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: ansible-role-diskimage-builder-centos-7
|
||||||
|
parent: ansible-role-diskimage-builder
|
||||||
|
nodeset: centos-7
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: ansible-role-diskimage-builder-fedora-26
|
||||||
|
parent: ansible-role-diskimage-builder
|
||||||
|
nodeset: fedora-26
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: ansible-role-diskimage-builder-ubuntu-xenial
|
||||||
|
parent: ansible-role-diskimage-builder
|
||||||
|
nodeset: ubuntu-xenial
|
||||||
|
|
||||||
|
- project:
|
||||||
|
name: openstack/ansible-role-diskimage-builder
|
||||||
|
templates:
|
||||||
|
- windmill-jobs-fedora-26
|
||||||
|
- windmill-jobs-xenial
|
||||||
|
check:
|
||||||
|
jobs:
|
||||||
|
- ansible-role-diskimage-builder-centos-7
|
||||||
|
- ansible-role-diskimage-builder-fedora-26
|
||||||
|
- ansible-role-diskimage-builder-ubuntu-xenial
|
||||||
|
- tox-linters
|
||||||
|
gate:
|
||||||
|
jobs:
|
||||||
|
- ansible-role-diskimage-builder-centos-7
|
||||||
|
- ansible-role-diskimage-builder-fedora-26
|
||||||
|
- ansible-role-diskimage-builder-ubuntu-xenial
|
||||||
|
- tox-linters
|
@ -20,6 +20,7 @@ diskimage_builder_task_manager:
|
|||||||
diskimage_builder_git_dest: /opt/ansible-role-diskimage-builder/git/openstack/diskimage-builder
|
diskimage_builder_git_dest: /opt/ansible-role-diskimage-builder/git/openstack/diskimage-builder
|
||||||
diskimage_builder_git_uri: https://git.openstack.org/openstack/diskimage-builder
|
diskimage_builder_git_uri: https://git.openstack.org/openstack/diskimage-builder
|
||||||
# diskimage_builder_git_refspec:
|
# diskimage_builder_git_refspec:
|
||||||
|
# diskimage_builder_git_update:
|
||||||
# diskimage_builder_git_version:
|
# diskimage_builder_git_version:
|
||||||
|
|
||||||
diskimage_builder_install_method: git
|
diskimage_builder_install_method: git
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
dest: "{{ diskimage_builder_git_dest }}"
|
dest: "{{ diskimage_builder_git_dest }}"
|
||||||
refspec: "{{ diskimage_builder_git_refspec|default(omit) }}"
|
refspec: "{{ diskimage_builder_git_refspec|default(omit) }}"
|
||||||
repo: "{{ diskimage_builder_git_uri }}"
|
repo: "{{ diskimage_builder_git_uri }}"
|
||||||
|
update: "{{ diskimage_builder_git_update|default(omit) }}"
|
||||||
version: "{{ diskimage_builder_git_version|default(omit) }}"
|
version: "{{ diskimage_builder_git_version|default(omit) }}"
|
||||||
|
|
||||||
- name: Set diskimage_builder_pip_name to local git repo.
|
- name: Set diskimage_builder_pip_name to local git repo.
|
||||||
|
@ -1,2 +0,0 @@
|
|||||||
[defaults]
|
|
||||||
roles_path = ../..
|
|
@ -1,2 +1 @@
|
|||||||
[all]
|
localhost
|
||||||
localhost ansible_connection=ssh
|
|
||||||
|
@ -12,16 +12,11 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
---
|
---
|
||||||
- hosts: localhost
|
- hosts: all
|
||||||
vars:
|
vars:
|
||||||
rolename: "{{ lookup('pipe', 'pwd') | dirname | basename }}"
|
diskimage_builder_git_dest: "{{ ansible_user_dir }}/src/git.openstack.org/openstack/diskimage-builder"
|
||||||
pre_tasks:
|
diskimage_builder_git_update: false
|
||||||
# Make sure OS does not have a stale package cache.
|
rolename: ansible-role-diskimage-builder
|
||||||
- name: Update apt cache.
|
|
||||||
become: yes
|
|
||||||
apt:
|
|
||||||
update_cache: yes
|
|
||||||
when: ansible_os_family == 'Debian'
|
|
||||||
|
|
||||||
roles:
|
roles:
|
||||||
- "{{ rolename }}"
|
- "{{ rolename }}"
|
||||||
@ -29,7 +24,7 @@
|
|||||||
post_tasks:
|
post_tasks:
|
||||||
- name: Register diskimage_builder_git_dest_stat.
|
- name: Register diskimage_builder_git_dest_stat.
|
||||||
stat:
|
stat:
|
||||||
path: /opt/ansible-role-diskimage-builder/git/openstack/diskimage-builder
|
path: /home/zuul/src/git.openstack.org/openstack/diskimage-builder
|
||||||
register: diskimage_builder_git_dest_stat
|
register: diskimage_builder_git_dest_stat
|
||||||
|
|
||||||
- name: Assert diskimage_builder_git_dest tests.
|
- name: Assert diskimage_builder_git_dest tests.
|
||||||
|
2
tox.ini
2
tox.ini
@ -31,7 +31,7 @@ exclude=.venv,.git,.tox,dist,doc,*openstack/common*,*lib/python*,*egg,build
|
|||||||
|
|
||||||
[testenv:linters]
|
[testenv:linters]
|
||||||
setenv =
|
setenv =
|
||||||
ANSIBLE_CONFIG = tests/ansible.cfg
|
ANSIBLE_ROLES_PATH = ..
|
||||||
whitelist_externals = bash
|
whitelist_externals = bash
|
||||||
commands =
|
commands =
|
||||||
# PEP8 Lint Check
|
# PEP8 Lint Check
|
||||||
|
Loading…
Reference in New Issue
Block a user