SessionAffinity를 사용하면 애플리케이션이 더 효율적으로 실행되고 사용자 경험이 향상될 수 있습니다.
apiVersion: v1
kind: Service
metadata:
name: http-go-svc
spec:
selector:
run: http-go
ports:
- protocol: TCP
port: 80
targetPort: 8080
---
apiVersion: apps/v1
kind: Deployment
metadata:
creationTimestamp: null
labels:
run: http-go
name: http-go
spec:
replicas: 1
selector:
matchLabels:
run: http-go
strategy: {}
template:
metadata:
creationTimestamp: null
labels:
run: http-go
spec:
containers:
- image: gasbugs/http-go
name: http-go
ports:
- containerPort: 8080
resources: {}
status: {}
kubectl run -it --rm --image=busybox bash
wget -O- -q [10.105.210.147]
kubectl run -it --rm --image=busybox bash
wget -O- -q [10.105.210.147]