From 19e62756cf10df2f92d59f330d5a4122549940f4 Mon Sep 17 00:00:00 2001 From: kevinschumacher Date: Sat, 26 Aug 2017 00:46:30 -0400 Subject: [PATCH] [incubator/etcd] #1785 namespace defined templates with chart name (#1835) --- incubator/etcd/Chart.yaml | 11 ++++++----- incubator/etcd/templates/_helpers.tpl | 2 +- incubator/etcd/templates/etcd-statefulset.yaml | 12 ++++++------ 3 files changed, 13 insertions(+), 12 deletions(-) diff --git a/incubator/etcd/Chart.yaml b/incubator/etcd/Chart.yaml index 771d714b6a..fb0780e004 100755 --- a/incubator/etcd/Chart.yaml +++ b/incubator/etcd/Chart.yaml @@ -1,10 +1,11 @@ name: etcd home: https://github.com/coreos/etcd -version: 0.2.2 -description: Distributed reliable key-value store for the most critical data of a distributed system. +version: 0.3.2 +description: Distributed reliable key-value store for the most critical data of a + distributed system. icon: https://raw.githubusercontent.com/coreos/etcd/master/logos/etcd-horizontal-color.png sources: - - https://github.com/coreos/etcd +- https://github.com/coreos/etcd maintainers: - - name: Lachlan Evenson - email: lachlan@deis.com +- name: Lachlan Evenson + email: lachlan@deis.com diff --git a/incubator/etcd/templates/_helpers.tpl b/incubator/etcd/templates/_helpers.tpl index c6b07b5c07..71f010566c 100644 --- a/incubator/etcd/templates/_helpers.tpl +++ b/incubator/etcd/templates/_helpers.tpl @@ -4,7 +4,7 @@ Create a default fully qualified app name. We truncate at 64 chars because some Kubernetes name fields are limited to this (by the DNS naming spec). */}} -{{- define "fullname" -}} +{{- define "etcd.fullname" -}} {{- $name := default .Chart.Name .Values.nameOverride -}} {{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" -}} {{- end -}} diff --git a/incubator/etcd/templates/etcd-statefulset.yaml b/incubator/etcd/templates/etcd-statefulset.yaml index 29c2b10f01..3b71fee1c9 100644 --- a/incubator/etcd/templates/etcd-statefulset.yaml +++ b/incubator/etcd/templates/etcd-statefulset.yaml @@ -4,7 +4,7 @@ metadata: annotations: service.alpha.kubernetes.io/tolerate-unready-endpoints: "true" metadata: - name: {{ template "fullname" . }} + name: {{ template "etcd.fullname" . }} labels: heritage: {{ .Release.Service | quote }} release: {{ .Release.Name | quote }} @@ -23,18 +23,18 @@ spec: apiVersion: apps/v1beta1 kind: StatefulSet metadata: - name: {{ template "fullname" . }} + name: {{ template "etcd.fullname" . }} labels: heritage: {{ .Release.Service | quote }} release: {{ .Release.Name | quote }} chart: "{{ .Chart.Name }}-{{ .Chart.Version }}" component: "{{ .Release.Name }}-{{ .Values.Component }}" spec: - serviceName: {{ template "fullname" . }} + serviceName: {{ template "etcd.fullname" . }} replicas: {{ default 3 .Values.Replicas }} template: metadata: - name: {{ template "fullname" . }} + name: {{ template "etcd.fullname" . }} labels: heritage: {{ .Release.Service | quote }} release: {{ .Release.Name | quote }} @@ -44,7 +44,7 @@ spec: pod.alpha.kubernetes.io/initialized: "true" spec: containers: - - name: {{ template "fullname" . }} + - name: {{ template "etcd.fullname" . }} image: "{{ .Values.Image }}:{{ .Values.ImageTag }}" imagePullPolicy: "{{ .Values.ImagePullPolicy }}" ports: @@ -60,7 +60,7 @@ spec: - name: INITIAL_CLUSTER_SIZE value: {{ default 3 .Values.Replicas | quote }} - name: SET_NAME - value: {{ template "fullname" . }} + value: {{ template "etcd.fullname" . }} volumeMounts: - name: datadir mountPath: /var/run/etcd