From 458bc6a2396461e55a4dc2b06c8624b170958314 Mon Sep 17 00:00:00 2001 From: Jingtao Ren Date: Fri, 19 Jan 2018 16:32:21 -0800 Subject: [PATCH] bring AutomountServiceAccountToken back in self_hosted.go --- pkg/util/k8sutil/self_hosted.go | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/pkg/util/k8sutil/self_hosted.go b/pkg/util/k8sutil/self_hosted.go index 8e12c5775..8b5e5cf12 100644 --- a/pkg/util/k8sutil/self_hosted.go +++ b/pkg/util/k8sutil/self_hosted.go @@ -141,13 +141,14 @@ done Spec: v1.PodSpec{ // Self-hosted etcd pod need to endure node restart. // If we set it to Never, the pod won't restart. If etcd won't come up, nor does other k8s API components. - RestartPolicy: v1.RestartPolicyAlways, - Containers: []v1.Container{c}, - Volumes: volumes, - HostNetwork: true, - DNSPolicy: v1.DNSClusterFirstWithHostNet, - Hostname: m.Name, - Subdomain: clusterName, + RestartPolicy: v1.RestartPolicyAlways, + Containers: []v1.Container{c}, + Volumes: volumes, + HostNetwork: true, + DNSPolicy: v1.DNSClusterFirstWithHostNet, + Hostname: m.Name, + Subdomain: clusterName, + AutomountServiceAccountToken: func(b bool) *bool { return &b }(false), }, }