-
Notifications
You must be signed in to change notification settings - Fork 36
/
Copy pathhostreaddeploy.yaml
59 lines (59 loc) · 1.24 KB
/
hostreaddeploy.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
apiVersion: apps/v1
kind: Deployment
metadata:
name: host-deploy
labels:
app: host-deploy
spec:
replicas: 2
minReadySeconds: 10
strategy:
type: RollingUpdate
rollingUpdate:
maxUnavailable: 1
maxSurge: 1
selector:
matchLabels:
app: host-deploy
template:
metadata:
labels:
app: host-deploy
spec:
containers:
- name: centos
image: centos
imagePullPolicy: Always
command: [ "sh", "-c"]
args:
- while true; do
tail /mnt/host/status.txt;
echo "reading status";
sleep 10000;
done;
ports:
- containerPort: 2580
name: http
# livenessProbe:
# httpGet:
# path: /
# port: 2580
# readinessProbe:
# httpGet:
# path: /
# port: 2580
# initialDelaySeconds: 10
# periodSeconds: 5
resources:
requests:
memory: "1000Mi"
cpu: "1000m"
volumeMounts:
- name: host-mount
mountPath: /mnt/host
readOnly: true
volumes:
- name: host-mount
hostPath:
path: /tmp
type: Directory