Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make chart registry configurable #114

Merged
merged 1 commit into from
Jul 9, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -283,8 +283,10 @@ manifests: gen-crds patch-crds label-crds gen-bindata gen-values-schema gen-char
.PHONY: gen
gen: clientset gen-crd-protos manifests openapi

CHART_VERSION ?=
APP_VERSION ?= $(CHART_VERSION)
CHART_REGISTRY ?= appscode
CHART_REGISTRY_URL ?= https://charts.appscode.com/stable/
CHART_VERSION ?=
APP_VERSION ?= $(CHART_VERSION)

.PHONY: update-charts
update-charts: $(shell find $$(pwd)/charts -maxdepth 1 -mindepth 1 -type d -printf 'chart-%f ')
Expand All @@ -293,6 +295,8 @@ chart-%:
@$(MAKE) chart-contents-$* gen-chart-doc-$* --no-print-directory

chart-contents-%:
@yq w -i ./charts/$*/doc.yaml repository.name --tag '!!str' $(CHART_REGISTRY)
@yq w -i ./charts/$*/doc.yaml repository.url --tag '!!str' $(CHART_REGISTRY_URL)
@if [ ! -z "$(CHART_VERSION)" ]; then \
yq w -i ./charts/$*/Chart.yaml version --tag '!!str' $(CHART_VERSION); \
yq w -i ./charts/$*/doc.yaml chart.version --tag '!!str' $(CHART_VERSION); \
Expand Down