Skip to content

Commit

Permalink
Merge pull request #68273 from sttts/sttts-non-fatal-in-cluster-config
Browse files Browse the repository at this point in the history
Automatic merge from submit-queue (batch tested with PRs 68265, 68273). If you want to cherry-pick this change to another branch, please follow the instructions here: https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md.

apiserver: make InClusterConfig errs for delegated authn/z non-fatal

Fixes kubernetes/kubernetes#68246:

Background:

In gci e2e tests the kube-controller-manager is started as static pod. When it first starts, there is no kubernetes service and the KUBERNETES_SERVICE_HOST and KUBERNETES_SERVICE_PORT env vars are not set inside the container.

When the kube-controller-manager is restarted, the KUBERNETES_SERVICE_HOST and KUBERNETES_SERVICE_PORT env vars are set, but the static pod has no service account, i.e. /var/run/secrets/kubernetes.io/serviceaccount/token does not exist. We made the later fatal in rest.InClusterConfig and its use to setup delegated authn/z.

Kubernetes-commit: 2c933695fa61d57d1c6fa5defb89caed7d49f773
  • Loading branch information
k8s-publishing-bot committed Sep 5, 2018
2 parents e9312c1 + 1a58e1c commit d41744b
Show file tree
Hide file tree
Showing 3 changed files with 209 additions and 203 deletions.
Loading

0 comments on commit d41744b

Please sign in to comment.