-
Notifications
You must be signed in to change notification settings - Fork 311
/
sts.quiz.0.2.partition.yaml
60 lines (60 loc) · 1.13 KB
/
sts.quiz.0.2.partition.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
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: quiz
labels:
app: quiz
spec:
serviceName: quiz-pods
updateStrategy:
type: RollingUpdate
rollingUpdate:
partition: 3
replicas: 3
selector:
matchLabels:
app: quiz
template:
metadata:
labels:
app: quiz
ver: "0.2"
spec:
volumes:
- name: db-data
persistentVolumeClaim:
claimName: db-data
containers:
- name: quiz-api
image: luksa/quiz-api:0.2
imagePullPolicy: Always
ports:
- name: http
containerPort: 8080
readinessProbe:
httpGet:
port: 8080
path: /healthz/ready
scheme: HTTP
- name: mongo
image: mongo:5
command:
- mongod
- --bind_ip
- 0.0.0.0
- --replSet
- quiz
volumeMounts:
- name: db-data
mountPath: /data/db
volumeClaimTemplates:
- metadata:
name: db-data
labels:
app: quiz
spec:
resources:
requests:
storage: 1Gi
accessModes:
- ReadWriteOnce