geerlingguy / kubernetes-101

Kubernetes 101 - by Jeff Geerling
https://kube101.jeffgeerling.com/
MIT License
555 stars 166 forks source link

Lesson Learned #19

Closed MichaelLeeHobbs closed 3 years ago

MichaelLeeHobbs commented 3 years ago

Been using Docker for years so I'm not exactly paying close attention. I've used kubespray and vagrant to build a cluster. While on episode 3 I wanted to be able to hit the hello app from my work station so I modified the expose command.

kubectl expose deployment hello-go --port=80 --target-port=8180 --type=NodePort --external-ip=192.168.1.171

192.168.1.171 being the IP of one of my two master nodes...

A.... few hours latter...

watch -n1 -x ip addr del 192.168.1.171/32 dev kube-ipvs0 <-- on each node

That continuously deletes the service ip from the ipvs interface give me time to run

kubectl delete service hello-go

Obviously, I could have just blown up the cluster and rebuilt it but I learned so much about how k8s works vs docker swarm.

Jeff as always keep up the good work! I started my DevOps journey many years ago with your book on Ansible.

stale[bot] commented 3 years ago

This issue has been marked 'stale' due to lack of recent activity. If there is no further activity, the issue will be closed in another 30 days. Thank you for your contribution!

Please read this blog post to see the reasons why I mark issues as stale.

stale[bot] commented 3 years ago

This issue has been closed due to inactivity. If you feel this is in error, please reopen the issue or file a new issue with the relevant details.