Merge "Gate: Add linter gate and path options to OSH-Infra"
This commit is contained in:
commit
c1f55190ac
.zuul.yaml
tools/gate/playbooks
15
.zuul.yaml
15
.zuul.yaml
@ -16,6 +16,8 @@
|
|||||||
name: openstack/openstack-helm-infra
|
name: openstack/openstack-helm-infra
|
||||||
check:
|
check:
|
||||||
jobs:
|
jobs:
|
||||||
|
- openstack-helm-infra-linter:
|
||||||
|
voting: true
|
||||||
- openstack-helm-infra-ubuntu:
|
- openstack-helm-infra-ubuntu:
|
||||||
voting: true
|
voting: true
|
||||||
- openstack-helm-infra-centos:
|
- openstack-helm-infra-centos:
|
||||||
@ -24,8 +26,15 @@
|
|||||||
voting: false
|
voting: false
|
||||||
gate:
|
gate:
|
||||||
jobs:
|
jobs:
|
||||||
|
- openstack-helm-infra-linter
|
||||||
- openstack-helm-infra-ubuntu
|
- openstack-helm-infra-ubuntu
|
||||||
|
|
||||||
|
- nodeset:
|
||||||
|
name: openstack-helm-single-node
|
||||||
|
nodes:
|
||||||
|
- name: primary
|
||||||
|
label: ubuntu-xenial
|
||||||
|
|
||||||
- nodeset:
|
- nodeset:
|
||||||
name: openstack-helm-ubuntu
|
name: openstack-helm-ubuntu
|
||||||
nodes:
|
nodes:
|
||||||
@ -79,6 +88,12 @@
|
|||||||
nodes:
|
nodes:
|
||||||
- node-1
|
- node-1
|
||||||
- node-2
|
- node-2
|
||||||
|
|
||||||
|
- job:
|
||||||
|
name: openstack-helm-infra-linter
|
||||||
|
run: tools/gate/playbooks/zuul-linter.yaml
|
||||||
|
nodeset: openstack-helm-single-node
|
||||||
|
|
||||||
- job:
|
- job:
|
||||||
name: openstack-helm-infra
|
name: openstack-helm-infra
|
||||||
pre-run: tools/gate/playbooks/zuul-pre.yaml
|
pre-run: tools/gate/playbooks/zuul-pre.yaml
|
||||||
|
@ -12,17 +12,24 @@
|
|||||||
# See the License for the specific language governing permissions and
|
# See the License for the specific language governing permissions and
|
||||||
# limitations under the License.
|
# limitations under the License.
|
||||||
|
|
||||||
- name: build the Kubeadm-AIO image
|
- name: Kubeadm-AIO build
|
||||||
docker_image:
|
block:
|
||||||
path: "{{ work_dir }}/"
|
#NOTE(portdirect): we do this to ensure we are feeding the docker build
|
||||||
name: "{{ images.kubernetes.kubeadm_aio }}"
|
# a clean path to work with.
|
||||||
dockerfile: "tools/images/kubeadm-aio/Dockerfile"
|
- name: Kubeadm-AIO image build path
|
||||||
force: yes
|
shell: cd "{{ work_dir }}"; pwd
|
||||||
pull: yes
|
register: kubeadm_aio_path
|
||||||
state: present
|
- name: build the Kubeadm-AIO image
|
||||||
rm: yes
|
docker_image:
|
||||||
buildargs:
|
path: "{{ kubeadm_aio_path.stdout }}/"
|
||||||
KUBE_VERSION: "{{ version.kubernetes }}"
|
name: "{{ images.kubernetes.kubeadm_aio }}"
|
||||||
CNI_VERSION: "{{ version.cni }}"
|
dockerfile: "tools/images/kubeadm-aio/Dockerfile"
|
||||||
HELM_VERSION: "{{ version.helm }}"
|
force: yes
|
||||||
CHARTS: "calico,flannel,tiller,kube-dns"
|
pull: yes
|
||||||
|
state: present
|
||||||
|
rm: yes
|
||||||
|
buildargs:
|
||||||
|
KUBE_VERSION: "{{ version.kubernetes }}"
|
||||||
|
CNI_VERSION: "{{ version.cni }}"
|
||||||
|
HELM_VERSION: "{{ version.helm }}"
|
||||||
|
CHARTS: "calico,flannel,tiller,kube-dns"
|
||||||
|
20
tools/gate/playbooks/zuul-linter.yaml
Normal file
20
tools/gate/playbooks/zuul-linter.yaml
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
# Copyright 2017 The Openstack-Helm Authors.
|
||||||
|
#
|
||||||
|
# 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.
|
||||||
|
|
||||||
|
- hosts: primary
|
||||||
|
tasks:
|
||||||
|
- name: Execute a Whitespace Linter check
|
||||||
|
command: find . -not -path "*/\.*" -not -path "*/doc/build/*" -not -name "*.tgz" -type f -exec egrep -l " +$" {} \;
|
||||||
|
register: result
|
||||||
|
failed_when: result.stdout != ""
|
@ -16,7 +16,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
gather_facts: False
|
gather_facts: False
|
||||||
become: yes
|
become: yes
|
||||||
roles:
|
roles:
|
||||||
@ -28,7 +28,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
gather_facts: True
|
gather_facts: True
|
||||||
roles:
|
roles:
|
||||||
- build-helm-packages
|
- build-helm-packages
|
||||||
@ -39,7 +39,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
gather_facts: True
|
gather_facts: True
|
||||||
become: yes
|
become: yes
|
||||||
roles:
|
roles:
|
||||||
@ -57,7 +57,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
gather_facts: False
|
gather_facts: False
|
||||||
become: yes
|
become: yes
|
||||||
roles:
|
roles:
|
||||||
@ -69,7 +69,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
gather_facts: True
|
gather_facts: True
|
||||||
roles:
|
roles:
|
||||||
- pull-images
|
- pull-images
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
roles:
|
roles:
|
||||||
- clean-host
|
- clean-host
|
||||||
tags:
|
tags:
|
||||||
@ -26,7 +26,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
roles:
|
roles:
|
||||||
- deploy-kubeadm-aio-master
|
- deploy-kubeadm-aio-master
|
||||||
tags:
|
tags:
|
||||||
@ -36,7 +36,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
roles:
|
roles:
|
||||||
- deploy-kubeadm-aio-node
|
- deploy-kubeadm-aio-node
|
||||||
tags:
|
tags:
|
||||||
@ -46,7 +46,7 @@
|
|||||||
vars_files:
|
vars_files:
|
||||||
- vars.yaml
|
- vars.yaml
|
||||||
vars:
|
vars:
|
||||||
work_dir: "{{ zuul.project.src_dir }}"
|
work_dir: "{{ zuul.project.src_dir }}/{{ zuul_osh_infra_relative_path | default('') }}"
|
||||||
roles:
|
roles:
|
||||||
- deploy-helm-packages
|
- deploy-helm-packages
|
||||||
tags:
|
tags:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user