-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
43 lines (33 loc) · 1.02 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
CHART_REPO := http://jenkins-x-chartmuseum:8080
NAME := empty
OS := $(shell uname)
CHARTMUSEUM_CREDS_USR := $(shell cat /builder/home/basic-auth-user.json)
CHARTMUSEUM_CREDS_PSW := $(shell cat /builder/home/basic-auth-pass.json)
init:
helm init --client-only
setup: init
helm repo add jenkinsxio http://chartmuseum.jenkins-x.io
build: clean setup
helm dependency build empty
helm lint empty
install: clean build
helm upgrade ${NAME} empty --install
upgrade: clean build
helm upgrade ${NAME} empty --install
delete:
helm delete --purge ${NAME} empty
clean:
rm -rf empty/charts
rm -rf empty/${NAME}*.tgz
rm -rf empty/requirements.lock
release: clean build
ifeq ($(OS),Darwin)
sed -i "" -e "s/version:.*/version: $(VERSION)/" empty/Chart.yaml
else ifeq ($(OS),Linux)
sed -i -e "s/version:.*/version: $(VERSION)/" empty/Chart.yaml
else
exit -1
endif
helm package empty
curl --fail -u $(CHARTMUSEUM_CREDS_USR):$(CHARTMUSEUM_CREDS_PSW) --data-binary "@$(NAME)-$(VERSION).tgz" $(CHART_REPO)/api/charts
rm -rf ${NAME}*.tgz