diff options
Diffstat (limited to 'f3s/ychat/helm-chart/templates/deployment.yaml')
| -rw-r--r-- | f3s/ychat/helm-chart/templates/deployment.yaml | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/f3s/ychat/helm-chart/templates/deployment.yaml b/f3s/ychat/helm-chart/templates/deployment.yaml new file mode 100644 index 0000000..53f8443 --- /dev/null +++ b/f3s/ychat/helm-chart/templates/deployment.yaml @@ -0,0 +1,66 @@ +apiVersion: apps/v1 +kind: Deployment +metadata: + name: ychat + namespace: services +spec: + replicas: 1 + # Recreate: single-instance stateful-in-memory chat; avoid two pods racing + # for the same Service while the old one drains its sessions. + strategy: + type: Recreate + selector: + matchLabels: + app: ychat + template: + metadata: + labels: + app: ychat + spec: + securityContext: + runAsNonRoot: true + runAsUser: 1000 + runAsGroup: 1000 + fsGroup: 1000 + containers: + - name: ychat + image: registry.lan.buetow.org:30001/ychat:f387bac + imagePullPolicy: IfNotPresent + securityContext: + allowPrivilegeEscalation: false + readOnlyRootFilesystem: true + runAsNonRoot: true + runAsUser: 1000 + runAsGroup: 1000 + ports: + - containerPort: 2000 + name: http + # yChat speaks HTTP/0.9-style responses (no status line), so an + # httpGet probe would never succeed. Use a TCP socket probe instead. + livenessProbe: + tcpSocket: + port: http + initialDelaySeconds: 5 + periodSeconds: 15 + readinessProbe: + tcpSocket: + port: http + initialDelaySeconds: 3 + periodSeconds: 10 + resources: + requests: + memory: 32Mi + cpu: 25m + limits: + memory: 128Mi + cpu: 250m + volumeMounts: + - name: log + mountPath: /app/log + - name: tmp + mountPath: /tmp + volumes: + - name: log + emptyDir: {} + - name: tmp + emptyDir: {}
\ No newline at end of file |
