-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile
41 lines (32 loc) · 1.17 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
.DEFAULT_GOAL := all
CHART := java
RELEASE := chart-${CHART}-release
NAMESPACE := chart-tests
TEST := ${RELEASE}-${CHART}-test
ACR := hmctspublic
ACR_SUBSCRIPTION := DCD-CFTAPPS-DEV
AKS_RESOURCE_GROUP := cft-preview-00-rg
AKS_CLUSTER := cft-preview-00-aks
setup:
az account set --subscription ${ACR_SUBSCRIPTION}
az configure --defaults acr=${ACR}
az aks get-credentials --resource-group ${AKS_RESOURCE_GROUP} --name ${AKS_CLUSTER}
clean:
-helm uninstall ${RELEASE} -n ${NAMESPACE}
-kubectl delete pod ${TEST} -n ${NAMESPACE}
lint:
helm lint ${CHART} -f ci-values.yaml
helm lint ${CHART} -f ci-tests-values.yaml
template:
helm template ${CHART} -f ci-values.yaml
helm template ${CHART} -f ci-tests-values.yaml
deploy:
helm install ${RELEASE} ${CHART} --namespace ${NAMESPACE} -f ci-values.yaml --wait --timeout 60s
dry-run:
helm dependency update ${CHART}
helm install ${RELEASE} ${CHART} --namespace ${NAMESPACE} -f ci-values.yaml --dry-run --debug
helm install ${RELEASE} ${CHART} --namespace ${NAMESPACE} -f ci-tests-values.yaml --dry-run --debug
test:
helm test ${RELEASE} --namespace ${NAMESPACE}
all: setup clean lint deploy test
.PHONY: setup clean lint deploy test all