- DevOps with Kubernetes
- Hideto Saito Hui Chuan Chloe Lee Cheng Yang Wu
- 172字
- 2021-07-02 13:41:55
Services
Services in Kubernetes are abstraction layers for routing traffic to a logical set of pods. With Services, we don't need to trace the IP address of each pod. Services usually use the label selector to select the pods that they need to route to while, in some cases, Services are created without a selector on purpose. The Service abstraction is powerful. It enables decoupling and makes communication between micro-services possible. Currently, Kubernetes Services support TCP, UDP, and SCTP.
Services don't care about how we create the pod. Just like ReplicaSet, it only cares that the pods match its label selectors, so the pods could belong to different ReplicaSets:

In the preceding diagram, all of the pods match the service selector, project=chapter3, service=web, so the Service will be responsible for distributing the traffic into all of the pods without explicit assignment.
There are four types of Services: ClusterIP, NodePort, LoadBalancer, and ExternalName:

- Extending Jenkins
- JavaFX Essentials
- Python網絡爬蟲從入門到實踐(第2版)
- Python爬蟲開發與項目實戰
- Object-Oriented JavaScript(Second Edition)
- Magento 1.8 Development Cookbook
- Yii Project Blueprints
- 小程序,巧應用:微信小程序開發實戰(第2版)
- 后臺開發:核心技術與應用實踐
- Learning Grunt
- Python預測分析實戰
- Mastering VMware vSphere Storage
- 編程風格:程序設計與系統構建的藝術(原書第2版)
- Learning Unity Physics
- C語言從入門到精通(第4版)