-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathiperf-client-job.yaml
executable file
·51 lines (50 loc) · 1.56 KB
/
iperf-client-job.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
apiVersion: batch/v1
kind: Job
metadata:
labels:
run: iperf3-client
name: iperf3-client
# namespace: iperf
spec:
# Set to match number of available server instances, default is 1
# Relying on the svc to round robin the clients to the servers doesnt seem to work, so have to generate
# different job files with the different endpoints of the servers you wish to connect to
parallelism: 1
template:
metadata:
labels:
run: iperf3-client
# annotations:
# k8s.v1.cni.cncf.io/networks: mqns/tengig
spec:
affinity:
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- labelSelector:
deployment: iperf3-server
job-name: iperf3-client
topologyKey: kubernetes.io/hostname
containers:
- env:
- name: IPERF3_HOSTNAME
value: iperf3-server
# value: 172.30.218.144
# image: uk.icr.io/mqperf/iperf3-client
image: docker.io/stmassey/iperf3-client
# imagePullPolicy: IfNotPresent
imagePullPolicy: Always
name: iperf3-client
resources:
requests:
memory: "1Gi"
cpu: "2"
limits:
memory: "1Gi"
cpu: "2"
terminationMessagePath: /dev/termination-log
dnsPolicy: ClusterFirst
restartPolicy: OnFailure
securityContext: {}
terminationGracePeriodSeconds: 30
# nodeSelector:
# kubernetes.io/hostname : worker5.<hostname>