Bläddra i källkod

YAML scripts used to deploy on Kubernetes

Johan Mereaux 6 år sedan
förälder
incheckning
02d7783960

+ 36 - 0
k8s/jicofo-deployment.yaml

@@ -0,0 +1,36 @@
+apiVersion: extensions/v1beta1
+kind: Deployment
+metadata:
+  labels:
+    service: jicofo
+  name: jicofo
+spec:
+  replicas: 1
+  strategy:
+    type: Recreate
+  template:
+    metadata:
+      labels:
+        service: jicofo
+    spec:
+      containers:
+      - env:
+        - name: XMPP_SERVER
+          value: <IP address of the prosody ClusterIP service>
+        - name: XMPP_DOMAIN
+          value: meet.jitsi
+        - name: XMPP_AUTH_DOMAIN
+          value: auth.meet.jitsi
+        - name: JICOFO_COMPONENT_SECRET
+          value: s3cr37
+        - name: JICOFO_AUTH_USER
+          value: focus
+        - name: JICOFO_AUTH_PASSWORD
+          value: passw0rd
+        - name: TZ
+          value: Europe/Paris
+        image: jitsi/jicofo
+        name: jicofo
+        resources: {}
+      restartPolicy: Always
+status: {}

+ 42 - 0
k8s/jvb-deployment.yaml

@@ -0,0 +1,42 @@
+apiVersion: extensions/v1beta1
+kind: Deployment
+metadata:
+  labels:
+    service: jvb
+  name: jvb
+spec:
+  replicas: 1
+  strategy:
+    type: Recreate
+  template:
+    metadata:
+      labels:
+        service: jvb
+    spec:
+      containers:
+      - env:
+        - name: XMPP_SERVER
+          value: <IP address of the prosody ClusterIP service>
+        - name: DOCKER_HOST_ADDRESS
+          value: <External IP address of the LoadBalancer service exposing the UDP:10000 TCP:4443 ports of the videobridge>
+        - name: XMPP_DOMAIN
+          value: meet.jitsi
+        - name: XMPP_AUTH_DOMAIN
+          value: auth.meet.jitsi
+        - name: JVB_COMPONENT_SECRET
+          value: s3cr3t
+        - name: JVB_STUN_SERVERS
+          value: stun.l.google.com:19302,stun1.l.google.com:19302,stun2.l.google.com:19302
+        - name: JICOFO_AUTH_USER
+          value: focus
+        - name: TZ
+          value: Europe/Paris
+        image: jitsi/jvb
+        name: jvb
+        ports:
+        - containerPort: 10000
+          protocol: UDP
+        - containerPort: 4443
+        resources: {}
+      restartPolicy: Always
+status: {}

+ 36 - 0
k8s/jvb-service-lb.yaml

@@ -0,0 +1,36 @@
+apiVersion: v1
+kind: Service
+metadata:
+  labels:
+    service: jvb
+  name: jvb-tcp
+spec:
+  type: LoadBalancer
+  loadBalancerIP: <External IP address you want to assign to your service>
+  ports:
+  - name: "4443"
+    port: 4443
+    targetPort: 4443
+  selector:
+    service: jvb
+status:
+  loadBalancer: {}
+---
+apiVersion: v1
+kind: Service
+metadata:
+  labels:
+    service: jvb
+  name: jvb-udp
+spec:
+  type: LoadBalancer
+  loadBalancerIP: <External IP address you want to assign to your service>
+  ports:
+  - name: "10000"
+    port: 10000
+    protocol: UDP
+    targetPort: 10000
+  selector:
+    service: jvb
+status:
+  loadBalancer: {}

+ 42 - 0
k8s/prosody-deployment.yaml

@@ -0,0 +1,42 @@
+apiVersion: extensions/v1beta1
+kind: Deployment
+metadata:
+  labels:
+    service: prosody
+  name: prosody
+spec:
+  replicas: 1
+  strategy:
+    type: Recreate
+  template:
+    metadata:
+      labels:
+        service: prosody
+    spec:
+      containers:
+      - env:
+        - name: XMPP_DOMAIN
+          value: meet.jitsi
+        - name: XMPP_AUTH_DOMAIN
+          value: auth.meet.jitsi
+        - name: XMPP_MUC_DOMAIN
+          value: muc.meet.jitsi
+        - name: JICOFO_COMPONENT_SECRET
+          value: s3cr37
+        - name: JVB_COMPONENT_SECRET
+          value: s3cr3t
+        - name: JICOFO_AUTH_USER
+          value: focus
+        - name: JICOFO_AUTH_PASSWORD
+          value: passw0rd
+        - name: TZ
+          value: Europe/Paris
+        image: jitsi/prosody
+        name: prosody
+        ports:
+        - containerPort: 5222
+        - containerPort: 5280
+        - containerPort: 5347
+        resources: {}
+      restartPolicy: Always
+status: {}

+ 21 - 0
k8s/prosody-service.yaml

@@ -0,0 +1,21 @@
+apiVersion: v1
+kind: Service
+metadata:
+  labels:
+    service: prosody
+  name: prosody
+spec:
+  ports:
+  - name: "5222"
+    port: 5222
+    targetPort: 5222
+  - name: "5280"
+    port: 5280
+    targetPort: 5280
+  - name: "5347"
+    port: 5347
+    targetPort: 5347
+  selector:
+    service: prosody
+status:
+  loadBalancer: {}

+ 36 - 0
k8s/web-deployment.yaml

@@ -0,0 +1,36 @@
+apiVersion: extensions/v1beta1
+kind: Deployment
+metadata:
+  labels:
+    service: web
+  name: web
+spec:
+  replicas: 1
+  strategy:
+    type: Recreate
+  template:
+    metadata:
+      labels:
+        service: web
+    spec:
+      containers:
+      - env:
+        - name: JICOFO_AUTH_USER
+          value: focus
+        - name: XMPP_DOMAIN
+          value: meet.jitsi
+        - name: XMPP_AUTH_DOMAIN
+          value: auth.meet.jitsi
+        - name: XMPP_BOSH_URL_BASE
+          value: http://prosody:5280
+        - name: XMPP_MUC_DOMAIN
+          value: muc.meet.jitsi
+        - name: TZ
+          value: Europe/Paris
+        image: jitsi/web
+        name: web
+        ports:
+        - containerPort: 80
+        - containerPort: 443
+        resources: {}
+status: {}

+ 17 - 0
k8s/web-ingress.yaml

@@ -0,0 +1,17 @@
+ apiVersion: extensions/v1beta1
+ kind: Ingress
+ metadata:
+   name: webingress
+ spec:
+   tls:
+   - hosts:
+     - <your ingress hostname>
+     secretName: <tls secret for your ingress hostname>
+   rules:
+   - host: <your ingress hostname>
+     http:
+       paths:
+       - path: /
+         backend:
+           serviceName: web
+           servicePort: 80

+ 16 - 0
k8s/web-service.yaml

@@ -0,0 +1,16 @@
+apiVersion: v1
+kind: Service
+metadata:
+  labels:
+    service: web
+  name: web
+spec:
+  ports:
+  - name: "http"
+    port: 80
+    targetPort: 80
+  - name: "https"
+    port: 443
+    targetPort: 443
+  selector:
+    service: web