-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall.yml
63 lines (63 loc) · 1.29 KB
/
install.yml
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
apiVersion: v1
kind: ServiceAccount
metadata:
name: k8s-ping
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: k8s-ping
rules:
- apiGroups:
- ""
- apps
resources:
- pods
verbs: ["list"]
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
name: k8s-ping
subjects:
- kind: ServiceAccount
namespace: default
name: k8s-ping
roleRef:
kind: ClusterRole
name: k8s-ping
apiGroup: rbac.authorization.k8s.io
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: k8s-ping
spec:
selector:
matchLabels:
app: k8s-ping
replicas: 3
template:
metadata:
labels:
app: k8s-ping
spec:
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
labelSelector:
matchExpressions:
- key: app
operator: In
values:
- k8s-ping
topologyKey: kubernetes.io/hostname
containers:
- name: k8s-ping
command: ["k8s-ping", "-d", "1000", "-n", "default"]
image: ghcr.io/kentik/k8s-ping
imagePullPolicy: Always
serviceAccount: k8s-ping
---