k8s-manifests/rds/base/charts/layer1_port_zenodo/templates/deployment.yaml

74 lines
2 KiB
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "layer1_port_zenodo.fullname" . }}
namespace: {{ .Release.Namespace }}
labels:
{{ include "layer1_port_zenodo.labels" . | indent 4 }}
spec:
replicas: {{ .Values.replicaCount }}
selector:
matchLabels:
{{ include "layer1_port_zenodo.labels" . | indent 6 }}
template:
metadata:
labels:
{{ include "layer1_port_zenodo.labels" . | indent 8 }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
containers:
- name: {{ .Chart.Name }}
image: {{ template "layer1_port_zenodo.image" . }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
env:
- name: ZENODO_OAUTH_CLIENT_ID
valueFrom:
secretKeyRef:
name: zenodo-client
key: zenodo-client-id
- name: ZENODO_OAUTH_CLIENT_SECRET
valueFrom:
secretKeyRef:
name: zenodo-client
key: zenodo-client-secret
envFrom:
- configMapRef:
name: mservice
- configMapRef:
name: proxy
- configMapRef:
name: globalenvvar
- configMapRef:
name: portzenodoconfig
ports:
- name: http
containerPort: 8080
protocol: TCP
livenessProbe:
httpGet:
path: /metrics
port: http
periodSeconds: 10
readinessProbe:
httpGet:
path: /metrics
port: http
periodSeconds: 10
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}