config/static-pods/master/api-haproxy.yaml

36 lines
807 B
YAML
Raw Normal View History

2023-05-15 14:36:48 +00:00
apiVersion: v1
kind: Pod
metadata:
namespace: kube-system
name: k8s-api-haproxy
labels:
component: k8s-api-haproxy
tier: control-plane
spec:
hostNetwork: true
dnsPolicy: Default
priorityClassName: system-node-critical
automountServiceAccountToken: false
tolerations:
- key: node.kubernetes.io/not-ready
effect: NoSchedule
containers:
- name: api-haproxy
image: haproxy:2.4.19-alpine
{{ if .vars.control_plane.reserve_resources }}
resources:
requests:
cpu: 10m
memory: 16Mi
{{ end }}
volumeMounts:
- name: config
mountPath: /usr/local/etc/haproxy/haproxy.cfg
readOnly: true
volumes:
- name: config
hostPath:
type: File
path: /etc/kubernetes/haproxy-api.cfg