* Upgrade base image to ruby 2.7
[arvados-k8s.git] / charts / arvados / templates / slurm-compute-deployment.yaml
1 # Copyright (C) The Arvados Authors. All rights reserved.
2 #
3 # SPDX-License-Identifier: Apache-2.0
4
5 apiVersion: apps/v1
6 kind: StatefulSet
7 metadata:
8   name: "arvados-slurm-compute"
9   labels:
10     app: arvados-slurm-compute
11     chart: {{ template "arvados.chart" . }}
12     release: {{ .Release.Name }}
13     heritage: {{ .Release.Service }}
14 spec:
15   replicas: {{ .Values.compute.nodes }}
16   podManagementPolicy: Parallel
17   serviceName: arvados-slurm-compute
18   selector:
19     matchLabels:
20       app: arvados-slurm-compute
21       release: {{ .Release.Name }}
22   template:
23     metadata:
24       labels:
25         app: arvados-slurm-compute
26         release: {{ .Release.Name }}
27     spec:
28       dnsConfig:
29         searches:
30           - "arvados-slurm-compute.{{ .Release.Namespace }}.svc.cluster.local"
31       terminationGracePeriodSeconds: 1
32       containers:
33         - name: {{ .Chart.Name }}
34           image: "cure/arvados-slurm-runtime"
35           imagePullPolicy: {{ .Values.image.pullPolicy }}
36           command:
37             - "sh"
38             - "-c"
39             - "/usr/local/bin/bootstrap.sh python3-arvados-python-client={{ .Values.arvados.versions.distribution.pythonArvadosPythonClient }} crunch-run={{ .Values.arvados.versions.distribution.crunchRun }} python3-arvados-fuse={{ .Values.arvados.versions.distribution.pythonArvadosFuse }} && mkdir /munge && cp -p /etc/munge/munge.key /munge && chown munge:munge /munge/munge.key && mkdir /var/slurm && chmod 700 /var/slurm && sudo -u munge munged --key-file=/munge/munge.key && /etc/init.d/docker start && slurmd -D"
40           securityContext:
41             privileged: true
42           env:
43             - name : ARVADOS_API_HOST
44               value: "{{ .Values.externalIP }}:444"
45             - name : ARVADOS_API_HOST_INSECURE
46               value: "true"
47             - name : ARVADOS_API_TOKEN
48               value: "{{ .Values.superUserSecret }}"
49           volumeMounts:
50             - name: slurm-configmap
51               mountPath: /etc/slurm-llnl/slurm.conf
52               subPath: slurm.conf
53             - name: slurm-configmap
54               mountPath: /etc/munge/munge.key
55               subPath: munge.key
56             - name: docker-graph-storage
57               mountPath: /var/lib/docker
58
59       volumes:
60         - name: slurm-configmap
61           configMap:
62             name: slurm-configmap
63             defaultMode: 0400
64         - name: docker-graph-storage
65           emptyDir: {}