apiVersion: apps/v1
kind: Deployment
metadata:
  name: coturn
spec:
  minReadySeconds: 10
  replicas: 1
  revisionHistoryLimit: 10
  selector:
    matchLabels:
      name: coturn
  strategy:
    type: Recreate
  template:
    metadata:
      annotations:
        prometheus.io/port: "8080"
        prometheus.io/scrape: "true"
      labels:
        name: coturn
    spec:
      containers:
      - image: coturn/coturn:4.5.2
        imagePullPolicy: Always
        name: coturn
        command: ["turnserver"]
        args: ["--log-file=stdout", "--external-ip=$$(detect-external-ip)", "--listening-port=8080", "--min-port=10000", "--max-port=10010", "--listening-ip=0.0.0.0", "--user=workadventure:WorkAdventure123", "--lt-cred-mech", "--server-name=bpi.eim.cloud-cenit.com", "--realm=bpi.eim.cloud-cenit.com"]
        ports:
        - containerPort: 8080
          name: p8080
        resources:
          limits:
            memory: "4Gi"
            cpu: "2000m"
          requests:
            memory: "1Gi"
            cpu: "1000m"