-
Notifications
You must be signed in to change notification settings - Fork 0
/
deployment.yaml
75 lines (75 loc) · 1.97 KB
/
deployment.yaml
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
63
64
65
66
67
68
69
70
71
72
73
74
75
apiVersion: apps/v1
kind: Deployment
metadata:
name: session-checker
spec:
replicas: 2
selector:
matchLabels:
app: session-checker
template:
metadata:
labels:
app: session-checker
azure.workload.identity/use: "true"
spec:
serviceAccountName: demoapp-sa
containers:
- name: session-checker
image: ghcr.io/torumakabe/session-checker:v1.3.3 # {"$imagepolicy": "flux-system:session-checker"}
imagePullPolicy: IfNotPresent
command: ["/session-checker"]
volumeMounts:
- name: secrets-store01-inline
mountPath: "/mnt/secrets-store"
readOnly: true
env:
- name: SESSION_CHECKER_REDIS_SERVER
valueFrom:
secretKeyRef:
name: demoapp-secret
key: redis-server
- name: SESSION_CHECKER_REDIS_PASSWORD
valueFrom:
secretKeyRef:
name: demoapp-secret
key: redis-password
livenessProbe:
httpGet:
path: /healthz
port: 8080
initialDelaySeconds: 5
periodSeconds: 5
readinessProbe:
httpGet:
path: /readyz
port: 8080
initialDelaySeconds: 5
periodSeconds: 5
securityContext:
allowPrivilegeEscalation: false
runAsNonRoot: true
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
runAsUser: 10001
runAsGroup: 10001
resources:
requests:
cpu: 10m
memory: 50Mi
limits:
cpu: 100m
memory: 100Mi
volumes:
- name: secrets-store01-inline
csi:
driver: secrets-store.csi.k8s.io
readOnly: true
volumeAttributes:
secretProviderClass: "azure-sync"
dnsPolicy: "Default"
securityContext:
seccompProfile:
type: RuntimeDefault