Skip to content

Instantly share code, notes, and snippets.

@jbeda

jbeda/registries.md

Created Jan 26, 2018
Embed
What would you like to do?
TGIK8s 23 notes

Remove cloud provider from cluster. This is a little hacky. It also might break your cluster. It did for me during the episode.

NODES=$(kubectl get nodes -o jsonpath="{range .items[*]}-H ubuntu@{.metadata.name} {end}")

sudo sed -e "/--cloud-provider=aws/d" -i /etc/kubernetes/manifests/kube-apiserver.yaml
sudo sed -e "/--cloud-provider=aws/d" -i /etc/kubernetes/manifests/kube-controller-manager.yaml

parallel-ssh -i -O StrictHostKeyChecking=no $NODES \
  sudo "sh -c 'sed -e "s/--cloud-provider=aws//g" -i /etc/systemd/system/kubelet.service.d/10-hostname.conf; \
        systemctl daemon-reload;
        systemctl restart kubelet'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment