aboutsummaryrefslogtreecommitdiff
path: root/templates/deployment.yaml
blob: f0ac30fcd63f579e9379a5a88be4965bec3624c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ template "invidious.fullname" . }}
  labels:
    {{- include "invidious.labels" . | nindent 4 }}
spec:
  replicas: {{ .Values.replicaCount }}
  selector:
    matchLabels:
      {{- include "invidious.selectorLabels" . | nindent 6 }}
  template:
    metadata:
      labels:
        {{- include "invidious.selectorLabels" . | nindent 8 }}
    spec:
      securityContext:
        runAsUser: {{ .Values.securityContext.runAsUser }}
        runAsGroup: {{ .Values.securityContext.runAsGroup }}
        fsGroup: {{ .Values.securityContext.fsGroup }}
      containers:
      - name: {{ .Chart.Name }}
        image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
        imagePullPolicy: {{ .Values.image.pullPolicy }}
        ports:
        - containerPort: 3000
        env:
        - name: INVIDIOUS_CONFIG
          valueFrom:
            configMapKeyRef:
              key: INVIDIOUS_CONFIG
              name: {{ template "invidious.fullname" . }}
        securityContext:
          allowPrivilegeEscalation: {{ .Values.securityContext.allowPrivilegeEscalation }}
          capabilities:
            drop:
            - ALL
        resources:
{{ toYaml .Values.resources | indent 10 }}
        readinessProbe:
          httpGet:
            port: 3000
            path: /
        livenessProbe:
          httpGet:
            port: 3000
            path: /
          initialDelaySeconds: 15
      restartPolicy: Always
...