video-iac/k8s/coturn/templates/deployment.yml

54 lines
1.4 KiB
YAML
Raw Normal View History

2021-11-09 13:16:32 +00:00
apiVersion: apps/v1
kind: Deployment
metadata:
2021-11-12 17:31:53 +00:00
name: coturn
2021-11-09 13:16:32 +00:00
labels:
app: coturn
spec:
selector:
matchLabels:
app: coturn
replicas: 1
template:
metadata:
2025-11-20 02:20:40 +00:00
labels:
app: coturn
annotations:
prometheus.io/scrape: "true"
prometheus.io/path: "/metrics"
2026-01-04 15:45:53 +00:00
prometheus.io/port: "9641"
2021-11-09 13:16:32 +00:00
spec:
hostNetwork: true
2026-01-04 17:44:59 +00:00
dnsPolicy: ClusterFirstWithHostNet
2021-11-09 13:16:32 +00:00
imagePullSecrets:
2026-01-04 15:45:53 +00:00
{{- toYaml .Values.imagePullSecrets | nindent 8 }}
2025-11-20 02:20:40 +00:00
volumes:
- name: coturn-config-volume
configMap:
name: coturn-config
2021-11-09 13:16:32 +00:00
containers:
- name: coturn
2026-01-04 15:45:53 +00:00
image: {{ .Values.image.repository }}:{{ .Values.image.tag }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
2025-11-20 02:20:40 +00:00
command: ["turnserver", "-c", "/etc/coturn/turnserver.conf"]
2021-11-18 19:50:42 +00:00
env:
- name: MY_POD_IP
valueFrom:
fieldRef:
fieldPath: status.podIP
2021-11-09 13:16:32 +00:00
ports:
2025-11-20 02:20:40 +00:00
- containerPort: 3478
name: coturn
volumeMounts:
- name: coturn-config-volume
mountPath: /etc/coturn/turnserver.conf
subPath: turnserver.conf
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}