
Previous changes enabled the auto-versioning of helm charts to ensure FluxCD helm controller recognizes chart changes. As a result of this refactor, the package name `stx-kubernetes-power-manager-helm` became outdated. This commit updates its name to `stx-kubernetes-power-manager`. It also improves chart versioning based on the Debian environment. Story: 2010929 Task: 49969 Test Plan: PASS: Build all packages generating an application tarball and check whether the charts' versions are correct. PASS: Validate basic application lifecycle operations: upload/apply/remove/delete. Author: Guilherme Santos <guilherme.santos@windriver.com> Change-Id: I82d3ce1ead5a4215268593b4cc9037b3e96074d7 Signed-off-by: Guilherme Santos <guilherme.santos@windriver.com>
45 lines
1007 B
Makefile
45 lines
1007 B
Makefile
#
|
|
# Copyright 2017 The Openstack-Helm Authors.
|
|
#
|
|
# Copyright (c) 2024 Wind River Systems, Inc.
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
# It's necessary to set this because some environments don't link sh -> bash.
|
|
SHELL := /bin/bash
|
|
TASK := build
|
|
|
|
EXCLUDES := helm-toolkit doc tests tools logs tmp
|
|
CHARTS := helm-toolkit $(filter-out $(EXCLUDES), $(patsubst %/.,%,$(wildcard */.)))
|
|
HELM_DIR := kubernetes-power-manager/helm/kubernetes-power-manager
|
|
|
|
.PHONY: $(EXCLUDES) $(CHARTS)
|
|
|
|
all: $(CHARTS)
|
|
|
|
$(CHARTS):
|
|
@if [ -d $@ ]; then \
|
|
echo; \
|
|
echo "===== Processing [$@] chart ====="; \
|
|
make $(TASK)-$@; \
|
|
fi
|
|
|
|
init-%:
|
|
if [ -f $*/Makefile ]; then make -C $*; fi
|
|
|
|
lint-%: init-%
|
|
if [ -d $* ]; then helm lint $(HELM_DIR); fi
|
|
|
|
build-%: lint-%
|
|
if [ -d $* ]; then \
|
|
helm package $(HELM_DIR) --version $(CHART_BASE_VERSION) --app-version $(CHART_APP_VERSION); \
|
|
fi
|
|
|
|
clean:
|
|
@echo "Clean all build artifacts"
|
|
rm -f */templates/_partials.tpl */templates/_globals.tpl
|
|
rm -rf */charts */tmpcharts
|
|
|
|
%:
|
|
@:
|