From 7306b4c28eadcd06a9f090546d6edec8a0067ac0 Mon Sep 17 00:00:00 2001 From: Martin Hickey Date: Fri, 24 Aug 2018 16:17:41 +0100 Subject: [PATCH] Fix helm create note for k8 label convention changes Update to note as per changes in Issue #4335 . Otherwise cannot retrieve the pod with the label names. --- pkg/chartutil/create.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/chartutil/create.go b/pkg/chartutil/create.go index ef70efed9..cff3b89eb 100644 --- a/pkg/chartutil/create.go +++ b/pkg/chartutil/create.go @@ -250,7 +250,7 @@ const defaultNotes = `1. Get the application URL by running these commands: export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ include ".fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}') echo http://$SERVICE_IP:{{ .Values.service.port }} {{- else if contains "ClusterIP" .Values.service.type }} - export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ include ".name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") + export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app.kubernetes.io/name={{ include ".name" . }},app.kubernetes.io/instance={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") echo "Visit http://127.0.0.1:8080 to use your application" kubectl port-forward $POD_NAME 8080:80 {{- end }}