2

I would like to add a flag to the kube-apiserver.

So I logged in the docker container of the kube-apiserver on the master node and went on a mission to find kube-apiserver.yaml. I heard reports that it was located in /etc/kubernetes/manifests/kube-apiserver.yaml.

Unfortunatly it was missing ! I only have a "SSL" directory in the /etc/kubernetes/" folder and the kube-apiserver.yaml is nowhere to be seen...


FYI :
Installed kubernetes 1.12.2 with Ansible playbook (kubespray).
Got 6 nodes and 3 masters.

Thx for your help

Doctor
  • 7,115
  • 4
  • 37
  • 55

1 Answers1

4

The kube-apiserver.yaml is in the directory you have specified - /etc/kubernetes/manifests/kube-apiserver.yaml but not on the kube-apiserver container/pod but on the master itself.

aurelius
  • 3,433
  • 1
  • 13
  • 22
  • Ohhh indeed ! Thx ! Do you know If there is a process watching changes in this file ? If I change a value in there will it be taken into account and the kube-api-server rebooted automatically ? – Doctor Jan 14 '19 at 15:14
  • yes, it should work like that - other behavior is a probable bug. You can find more information in this [answer](https://stackoverflow.com/questions/50007654/how-does-kube-apiserver-restart-after-editing-etc-kubernetes-manifests-kube-api). – aurelius Jan 14 '19 at 15:47
  • @Doctor make sure to plan you kubernetes version upgrade appropriately and make sure the changes are not overwritten by the upgrade process. I have not used kubespray, but kubeadm re-generate this file everytime based on it's own configuration. – Andrew Savinykh Jan 15 '19 at 03:06
  • Where would this be if I am using Docker Desktop for Windows 10 (using WSL 2 backend)? – Rob L Jan 13 '21 at 18:15