diff --git a/buzz/k8s/buzz-pair-relay.yaml b/buzz/k8s/buzz-pair-relay.yaml new file mode 100644 index 0000000..2a21547 --- /dev/null +++ b/buzz/k8s/buzz-pair-relay.yaml @@ -0,0 +1,77 @@ +--- +apiVersion: apps/v1 +kind: Deployment +metadata: + name: buzz-pair-relay + labels: + app: buzz-pair-relay +spec: + replicas: 1 + selector: + matchLabels: + app: buzz-pair-relay + template: + metadata: + labels: + app: buzz-pair-relay + spec: + nodeSelector: + kubernetes.io/hostname: djg-oracle-sl + tolerations: + - key: node-role.kubernetes.io/master + operator: Exists + effect: NoSchedule + - key: node-role.kubernetes.io/control-plane + operator: Exists + effect: NoSchedule + containers: + - name: buzz-pair-relay + image: ghcr.io/block/buzz:main + imagePullPolicy: IfNotPresent + command: ["buzz-pair-relay"] + env: + - name: BUZZ_PAIR_RELAY_BIND_ADDR + value: 0.0.0.0:5000 + ports: + - containerPort: 5000 + name: ws + resources: + requests: + cpu: 10m + memory: 16Mi + limits: + memory: 64Mi +--- +apiVersion: v1 +kind: Service +metadata: + name: buzz-pair +spec: + selector: + app: buzz-pair-relay + ports: + - port: 80 + targetPort: 5000 +--- +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: buzz-pair + annotations: + nginx.ingress.kubernetes.io/proxy-read-timeout: "120" +spec: + rules: + - host: ch4t.buzz + http: + paths: + - path: /pair + pathType: Prefix + backend: + service: + name: buzz-pair + port: + number: 80 + tls: + - hosts: + - ch4t.buzz + secretName: buzz-bestdadjokes-tls