self-hosted kubelet: listen on host IP
To avoid exposing it to the internet.
@@ -45,7 +45,8 @@ spec:
--read-only-port=0 \
--volume-plugin-dir=/var/lib/kubelet/volumeplugins \
--node-labels=$(grep NODE_LABELS /etc/kubernetes/kubelet.env | cut -d'"' -f2) \
- --register-with-taints=$(grep NODE_TAINTS /etc/kubernetes/kubelet.env | cut -d'"' -f2)
+ --register-with-taints=$(grep NODE_TAINTS /etc/kubernetes/kubelet.env | cut -d'"' -f2) \
+ --address=$(HOST_IP)
" | tee /tmp/start-kubelet.sh &&
chmod +x /tmp/start-kubelet.sh &&
/tmp/start-kubelet.sh
