标签:ada cluster adb lease api 组件 table sel 依赖
service依赖DNS组件(CoreDNS)
工作模式:userspace, iptables, ipvs
类型:ExternalName, ClusterIP, NodePort, LoadBalancer
apiVersion: v1
kind: Service
metadata:
name: redis
namespace: default
spec:
selector:
app: redis
role: logstor
clusterIP: 10.97.97.97
type: ClusterIP
ports:
- port: 6379
targetPort: 6379
apiVersion: v1
kind: Service
metadata:
name: myapp
namespace: default
spec:
selector:
app: myapp
release: canary
clusterIP: 10.99.99.99
type: NodePort
ports:
- port: 80
targetPort: 80
nodePort: 30080
# kubectl patch svc myapp -p '{"spec":{"sessionAffinity":"ClientIP"}}'
apiVersion: v1
kind: Service
metadata:
name: myapp
namespace: default
spec:
selector:
app: myapp
release: canary
clusterIP: None
ports:
- port: 80
targetPort: 80
# dig -t A myapp-svc.default.svc.cluster.local. @$DNS_IP
标签:ada cluster adb lease api 组件 table sel 依赖
原文地址:https://www.cnblogs.com/L-dongf/p/9932335.html