From 93a839f58894596186daf660d2ce9b423c3f97a1 Mon Sep 17 00:00:00 2001 From: Drew Walters Date: Thu, 28 Mar 2019 16:55:06 -0500 Subject: [PATCH] CI: Add chart build job for latest Helm toolkit This commit introduces a non-voting job to lint Helm charts against the latest version of Helm toolkit from OpenStack-Helm Infra. This job should serve as an indicator of when it's safe to advance the version of Helm toolkit used by Airship. Additionally, this commit modifies all Helm chart lint jobs to run on each commit, regardless of the files modified by a change. This should not introduce a noticeable difference in CI runtime, as these jobs execute quicker than the tox jobs. Change-Id: I0b38ef3388629b88ea6d6f88eabdc2d7f5f69a3b --- .zuul.yaml | 22 ++++++++++++++++------ tools/zuul/playbooks/helm-linter.yaml | 6 ++++-- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index 6f5beba6..2f959898 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -17,7 +17,8 @@ - airship-promenade-lint-ws - airship-promenade-docker-build-gate - airship-promenade-doc-build - - airship-promenade-lint-chart + - airship-promenade-chart-build-gate + - airship-promenade-chart-build-latest-htk - airship-promenade-unit-py35 gate: @@ -26,7 +27,7 @@ - airship-promenade-lint-ws - airship-promenade-docker-build-gate - airship-promenade-doc-build - - airship-promenade-lint-chart + - airship-promenade-chart-build-gate - airship-promenade-unit-py35 post: @@ -48,14 +49,23 @@ nodeset: airship-promenade-single-node - job: - name: airship-promenade-lint-chart + name: airship-promenade-chart-build-gate description: | - Lints Helm charts for validity + Lints charts using pinned HTK run: tools/zuul/playbooks/helm-linter.yaml timeout: 300 nodeset: airship-promenade-single-node - files: - - ^charts/.*$ + +- job: + name: airship-promenade-chart-build-latest-htk + description: | + Lints charts using latest HTK + voting: false + run: tools/zuul/playbooks/helm-linter.yaml + timeout: 300 + nodeset: airship-promenade-single-node + vars: + HTK_COMMIT: master - job: name: airship-promenade-unit-py35 diff --git a/tools/zuul/playbooks/helm-linter.yaml b/tools/zuul/playbooks/helm-linter.yaml index e20f7e05..9e449ac1 100644 --- a/tools/zuul/playbooks/helm-linter.yaml +++ b/tools/zuul/playbooks/helm-linter.yaml @@ -13,9 +13,11 @@ - hosts: primary tasks: - - name: Execute the make target for Helm chart linting + - name: Execute the make target to package Helm charts. make: chdir: "{{ zuul.project.src_dir }}" - target: helm-lint + target: charts + params: + HTK_COMMIT: "{{ HTK_COMMIT | default('') }}" register: result failed_when: result.failed