Still need to add thing like TLS but this will basically be the template for routing and service setup, going forward
21 lines
887 B
YAML
21 lines
887 B
YAML
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: whoami-lb
|
|
annotations:
|
|
service.beta.kubernetes.io/vultr-loadbalancer-protocol: "http"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-algorithm: "least_connections"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-healthcheck-protocol: "http"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-healthcheck-path: "/health"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-healthcheck-interval: "30"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-healthcheck-response-timeout: "5"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-healthcheck-unhealthy-threshold: "5"
|
|
service.beta.kubernetes.io/vultr-loadbalancer-healthcheck-healthy-threshold: "5"
|
|
spec:
|
|
type: LoadBalancer
|
|
selector:
|
|
name: whoami
|
|
ports:
|
|
- name: http
|
|
port: 80
|
|
targetPort: 8080 |