...
1apiVersion: edge.ncr.com/v1alpha1
2kind: Persistence
3metadata:
4 name: samhain
5 namespace: fim
6 labels:
7 platform.edge.ncr.com/component: fim
8spec:
9 statefulSet:
10 apiVersion: apps/v1
11 kind: StatefulSet
12 metadata:
13 name: samhain
14 namespace: fim
15 labels:
16 platform.edge.ncr.com/component: fim
17 spec:
18 replicas: 1
19 selector:
20 matchLabels:
21 platform.edge.ncr.com/component: fim
22 template:
23 metadata:
24 labels:
25 platform.edge.ncr.com/component: fim
26 spec:
27 priorityClassName: edge-p4-operability-services
28 initContainers:
29 - name: init-fim
30 image: bzl://cmd/sds/fim:container_push
31 command: ["sh", "/samhain/config/init-script.sh"]
32 resources:
33 limits:
34 cpu: "100m"
35 memory: "120Mi"
36 volumeMounts:
37 - name: config-map
38 mountPath: /samhain/config/samhainrc
39 subPath: samhainrc
40 - name: filter-map
41 mountPath: /samhain/config/filter
42 subPath: filter
43 - name: host-fs
44 readOnly: true
45 mountPath: /ien_fs/
46 - name: samhain-storage
47 mountPath: /samhain/db/
48 imagePullPolicy: IfNotPresent
49 containers:
50 - name: fim
51 image: bzl://cmd/sds/fim:container_push
52 command:
53 - /bin/bash
54 - -c
55 - |
56 /usr/bin/python3 /samhain/config/mount-monitor.py &
57 /samhain/sbin/samhain -t check -p err -f
58 resources:
59 limits:
60 cpu: "100m"
61 memory: "120Mi"
62 volumeMounts:
63 - name: config-map
64 mountPath: /samhain/config/samhainrc
65 subPath: samhainrc
66 - name: samhain-storage
67 mountPath: /samhain/db/
68 - name: host-fs
69 readOnly: true
70 mountPath: /ien_fs/
71 mountPropagation: HostToContainer
72 imagePullPolicy: IfNotPresent
73 tty: true
74 startupProbe:
75 exec:
76 command: [sh, -c, 'cat /samhain/samhain_log | grep "MARK" | tail -1 | grep "TIMESTAMP"']
77 failureThreshold: 60
78 periodSeconds: 10
79 volumes:
80 - name: config-map
81 configMap:
82 name: samhain-config
83 items:
84 - key: samhainrc
85 path: samhainrc
86 - name: filter-map
87 configMap:
88 name: samhain-filter
89 items:
90 - key: filter
91 path: filter
92 - name: host-fs
93 hostPath:
94 type: Directory
95 path: /
96 imagePullSecrets:
97 - name: edge-docker-pull-secret
98 volumeClaimTemplates:
99 - metadata:
100 name: samhain-storage
101 labels:
102 platform.edge.ncr.com/component: fim
103 spec:
104 resources:
105 requests:
106 storage: "64M"
107 accessModes: ["ReadWriteOnce"]
108 storageClassName: local-path
109 serviceName: samhain
110 updateStrategy: {}
View as plain text