From: Krzysztof Opasiak Date: Fri, 21 Feb 2020 12:50:42 +0000 (+0100) Subject: Add Makefile option to skip lining of helm charts X-Git-Tag: 6.0.0~371 X-Git-Url: https://gerrit.onap.org/r/gitweb?p=oom.git;a=commitdiff_plain;h=2d35b23f71670c54e4f12eaeb53466b657347818 Add Makefile option to skip lining of helm charts For some reason after introducing our awesome templates to ONAP make command can take now quite a lot of time, which sometimes causes out CI jobs to fail. Command that takes so much time is helm lint. This patch adds a Makefile option that allows you to skip linting of helm charts and just build them. Example: make SKIP_LINT=TRUE Default behavior stays unchanged. Issue-ID: OOM-2055 Signed-off-by: Krzysztof Opasiak Change-Id: Ic50bad0cc82892e1daecc5761d6144d788a79d9f --- diff --git a/kubernetes/Makefile b/kubernetes/Makefile index 3f41c3cc4b..7150f10c1f 100644 --- a/kubernetes/Makefile +++ b/kubernetes/Makefile @@ -20,6 +20,12 @@ OUTPUT_DIR := $(ROOT_DIR)/dist PACKAGE_DIR := $(OUTPUT_DIR)/packages SECRET_DIR := $(OUTPUT_DIR)/secrets +ifneq ($(SKIP_LINT),TRUE) + HELM_LINT_CMD := helm lint +else + HELM_LINT_CMD := echo "Skipping linting of" +endif + SUBMODS := robot aai EXCLUDES := config oneclick readiness test dist helm $(PARENT_CHART) dcae $(SUBMODS) HELM_CHARTS := $(filter-out $(EXCLUDES), $(patsubst %/.,%,$(wildcard */.))) $(PARENT_CHART) @@ -55,7 +61,7 @@ dep-%: make-% @if [ -f $*/requirements.yaml ]; then helm dep up $*; fi lint-%: dep-% - @if [ -f $*/Chart.yaml ]; then helm lint $*; fi + @if [ -f $*/Chart.yaml ]; then $(HELM_LINT_CMD) $*; fi package-%: lint-% @mkdir -p $(PACKAGE_DIR)