-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathDeploymentFastapi.yaml
More file actions
62 lines (62 loc) · 1.71 KB
/
DeploymentFastapi.yaml
File metadata and controls
62 lines (62 loc) · 1.71 KB
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
52
53
54
55
56
57
58
59
60
61
62
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "orcha.fullname" . }}-api
labels:
{{- include "orcha.labels" . | nindent 4 }}
app.kubernetes.io/component: api
spec:
replicas: {{ .Values.api.replicaCount }}
selector:
matchLabels:
{{- include "orcha.selectorLabels" . | nindent 6 }}
app.kubernetes.io/component: api
template:
metadata:
labels:
{{- include "orcha.selectorLabels" . | nindent 8 }}
app.kubernetes.io/component: api
spec:
containers:
- name: api
image: {{ include "orcha.image" . }}
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: 8080
protocol: TCP
envFrom:
- configMapRef:
name: {{ include "orcha.fullname" . }}
- secretRef:
name: {{ .Values.externalSecret.name }}
env:
{{- include "orcha.config.database" . | nindent 10 }}
- name: TENANTS_FILE_PATH
value: /etc/orcha/tenants.json
volumeMounts:
- name: tenants
mountPath: /etc/orcha
readOnly: true
livenessProbe:
httpGet:
path: /health
port: http
initialDelaySeconds: 15
periodSeconds: 30
readinessProbe:
httpGet:
path: /health
port: http
initialDelaySeconds: 10
periodSeconds: 10
resources:
{{- toYaml .Values.api.resources | nindent 12 }}
volumes:
- name: tenants
secret:
secretName: orcha-tenants
items:
- key: tenants.json
path: tenants.json