db30194e7c96eaef92a827142e7ff23839b5b694
[functest-kubernetes.git] / functest_kubernetes / rally / all-in-one.yaml
1 ---
2 version: 2
3 title: All in one tasks for checking basic functionality of Kubernetes cluster
4 subtasks:
5
6   - title: Run a single workload with listing existing kubernetes namespaces
7     scenario:
8       Kubernetes.list_namespaces: {}
9     runner:
10       constant:
11         concurrency: {{ concurrency }}
12         times: {{ times }}
13
14   - title: Run a single workload with create/read/delete namespace
15     scenario:
16       Kubernetes.create_and_delete_namespace: {}
17     runner:
18       constant:
19         concurrency: {{ concurrency }}
20         times: {{ times }}
21
22   - title: Run a single workload with create/read/delete pod
23     scenario:
24       Kubernetes.create_and_delete_pod:
25         image: {{ k8s_gcr_repo }}/pause:3.3
26     runner:
27       constant:
28         concurrency: {{ concurrency }}
29         times: {{ times }}
30     contexts:
31       namespaces:
32         count: {{ namespaces_count }}
33         with_serviceaccount: true
34
35   - title: Run a single workload with create/read/delete replication controller
36     scenario:
37       Kubernetes.create_and_delete_replication_controller:
38         image: {{ k8s_gcr_repo }}/pause:3.3
39         replicas: 2
40     runner:
41       constant:
42         concurrency: {{ concurrency }}
43         times: {{ times }}
44     contexts:
45       namespaces:
46         count: {{ namespaces_count }}
47         with_serviceaccount: true
48
49   - title: Run a single workload with create/scale/delete replication controller
50     scenario:
51       Kubernetes.create_scale_and_delete_replication_controller:
52         image: {{ k8s_gcr_repo }}/pause:3.3
53         replicas: 2
54         scale_replicas: 3
55     runner:
56       constant:
57         concurrency: {{ concurrency }}
58         times: {{ times }}
59     contexts:
60       namespaces:
61         count: {{ namespaces_count }}
62         with_serviceaccount: true
63
64   - title: Run a single workload with create/read/delete replicaset
65     scenario:
66       Kubernetes.create_and_delete_replicaset:
67         image: {{ k8s_gcr_repo }}/pause:3.3
68         replicas: 1
69     runner:
70       constant:
71         concurrency: {{ concurrency }}
72         times: {{ times }}
73     contexts:
74       namespaces:
75         count: {{ namespaces_count }}
76         with_serviceaccount: true
77
78   - title: Run a single workload with create/scale/delete replicaset
79     scenario:
80       Kubernetes.create_scale_and_delete_replicaset:
81         image: {{ k8s_gcr_repo }}/pause:3.3
82         replicas: 1
83         scale_replicas: 2
84     runner:
85       constant:
86         concurrency: {{ concurrency }}
87         times: {{ times }}
88     contexts:
89       namespaces:
90         count: {{ namespaces_count }}
91         with_serviceaccount: true
92
93   - title:
94       Run a single workload with create/read/delete pod with emptyDir volume
95     scenario:
96       Kubernetes.create_and_delete_pod_with_emptydir_volume:
97         image: {{ k8s_gcr_repo }}/pause:3.3
98         mount_path: /opt/check
99     runner:
100       constant:
101         concurrency: {{ concurrency }}
102         times: {{ times }}
103     contexts:
104       namespaces:
105         count: {{ namespaces_count }}
106         with_serviceaccount: true
107
108   - title: >-
109       Run a single workload with create/read/check/delete pod with emptyDir
110       volume
111     scenario:
112       Kubernetes.create_and_delete_pod_with_emptydir_volume:
113         image: {{ dockerhub_repo }}/busybox:1.28
114         command:
115           - sleep
116           - "3600"
117         mount_path: /opt/check
118         check_cmd:
119           - ls
120           - /opt/check
121         error_regexp: No such file
122     runner:
123       constant:
124         concurrency: {{ concurrency }}
125         times: {{ times }}
126     contexts:
127       namespaces:
128         count: {{ namespaces_count }}
129         with_serviceaccount: true
130
131   - title: Run a single workload with create/read/delete pod with secret volume
132     scenario:
133       Kubernetes.create_and_delete_pod_with_secret_volume:
134         image: {{ dockerhub_repo }}/busybox:1.28
135         command:
136           - sleep
137           - "3600"
138         mount_path: /opt/check
139     runner:
140       constant:
141         concurrency: {{ concurrency }}
142         times: {{ times }}
143     contexts:
144       namespaces:
145         count: {{ namespaces_count }}
146         with_serviceaccount: true
147
148   - title: Run a single workload with create/check/delete pod with secret volume
149     scenario:
150       Kubernetes.create_and_delete_pod_with_secret_volume:
151         image: {{ dockerhub_repo }}/busybox:1.28
152         command:
153           - sleep
154           - "3600"
155         mount_path: /opt/check
156         check_cmd:
157           - ls
158           - /opt/check
159         error_regexp: No such file
160     runner:
161       constant:
162         concurrency: {{ concurrency }}
163         times: {{ times }}
164     contexts:
165       namespaces:
166         count: {{ namespaces_count }}
167         with_serviceaccount: true
168
169   - title: >-
170       Run a single workload with create/read/check/delete pod with hostPath
171       volume
172     scenario:
173       Kubernetes.create_and_delete_pod_with_hostpath_volume:
174         image: {{ dockerhub_repo }}/busybox:1.28
175         command:
176           - sleep
177           - "3600"
178         mount_path: /opt/check
179         check_cmd:
180           - ls
181           - /opt/check
182         error_regexp: No such file
183         volume_type: Directory
184         volume_path: /tmp/
185     runner:
186       constant:
187         concurrency: {{ concurrency }}
188         times: {{ times }}
189     contexts:
190       namespaces:
191         count: {{ namespaces_count }}
192         with_serviceaccount: true
193
194   - title:
195       Run a single workload with create/read/delete pod with configMap volume
196     scenario:
197       Kubernetes.create_and_delete_pod_with_configmap_volume:
198         image: {{ dockerhub_repo }}/busybox:1.28
199         command:
200           - "sleep"
201           - "3600"
202         mount_path: /var/log/check.txt
203         subpath: check.txt
204         configmap_data:
205           check.txt: |
206             test
207     runner:
208       constant:
209         concurrency: {{ concurrency }}
210         times: {{ times }}
211     contexts:
212       namespaces:
213         count: {{ namespaces_count }}
214         with_serviceaccount: true
215
216   - title: >-
217       Run a single workload with create/read/check/delete pod with configMap
218       volume
219     scenario:
220       Kubernetes.create_and_delete_pod_with_configmap_volume:
221         image: {{ dockerhub_repo }}/busybox:1.28
222         command:
223           - "sleep"
224           - "3600"
225         mount_path: /var/log/check.txt
226         subpath: check.txt
227         configmap_data:
228           check.txt: |
229             test
230         check_cmd:
231           - cat
232           - /var/log/check.txt
233         error_regexp: No such file
234     runner:
235       constant:
236         concurrency: {{ concurrency }}
237         times: {{ times }}
238     contexts:
239       namespaces:
240         count: {{ namespaces_count }}
241         with_serviceaccount: true
242
243   - title: Run a single workload with create/read/delete deployment
244     scenario:
245       Kubernetes.create_and_delete_deployment:
246         image: {{ k8s_gcr_repo }}/pause:3.3
247         replicas: 2
248     runner:
249       constant:
250         concurrency: {{ concurrency }}
251         times: {{ times }}
252     contexts:
253       namespaces:
254         count: {{ namespaces_count }}
255         with_serviceaccount: true
256
257   - title: Run a single workload with create/rollout/delete deployment
258     scenario:
259       Kubernetes.create_rollout_and_delete_deployment:
260         image: {{ dockerhub_repo }}/busybox:1.28
261         replicas: 1
262         command:
263           - sleep
264           - "3600"
265         env:
266           - name: "UPD"
267             value: "false"
268         changes:
269           env:
270             - name: "UPD"
271               value: "true"
272     runner:
273       constant:
274         concurrency: {{ concurrency }}
275         times: {{ times }}
276     contexts:
277       namespaces:
278         count: {{ namespaces_count }}
279         with_serviceaccount: true
280
281   - title: Run a single workload with create/read/delete statefulset
282     scenario:
283       Kubernetes.create_and_delete_statefulset:
284         image: {{ k8s_gcr_repo }}/pause:3.3
285         replicas: 2
286     runner:
287       constant:
288         concurrency: {{ concurrency }}
289         times: {{ times }}
290     contexts:
291       namespaces:
292         count: {{ namespaces_count }}
293         with_serviceaccount: true
294
295   - title: Run a single workload with create/scale/delete statefulset
296     scenario:
297       Kubernetes.create_scale_and_delete_statefulset:
298         image: {{ k8s_gcr_repo }}/pause:3.3
299         replicas: 1
300         scale_replicas: 2
301     runner:
302       constant:
303         concurrency: {{ concurrency }}
304         times: {{ times }}
305     contexts:
306       namespaces:
307         count: {{ namespaces_count }}
308         with_serviceaccount: true
309
310   - title: Run a single workload with create/read/delete job
311     scenario:
312       Kubernetes.create_and_delete_job:
313         image: {{ dockerhub_repo }}/busybox:1.28
314         command:
315           - echo
316           - "SUCCESS"
317     runner:
318       constant:
319         concurrency: {{ concurrency }}
320         times: {{ times }}
321     contexts:
322       namespaces:
323         count: {{ namespaces_count }}
324         with_serviceaccount: true
325
326   - title: Run a single workload with create/check/delete clusterIP service
327     scenario:
328       Kubernetes.create_check_and_delete_pod_with_cluster_ip_service:
329         image: {{ gcr_repo }}/google-samples/hello-go-gke:1.0
330         port: 80
331         protocol: TCP
332     runner:
333       constant:
334         concurrency: {{ concurrency }}
335         times: {{ times }}
336     contexts:
337       namespaces:
338         count: {{ namespaces_count }}
339         with_serviceaccount: true
340
341   - title: >-
342       Run a single workload with create/check/delete clusterIP service with
343       custom endpoint
344     scenario:
345       Kubernetes.create_check_and_delete_pod_with_cluster_ip_service:
346         image: {{ gcr_repo }}/google-samples/hello-go-gke:1.0
347         port: 80
348         protocol: TCP
349         custom_endpoint: true
350     runner:
351       constant:
352         concurrency: {{ concurrency }}
353         times: {{ times }}
354     contexts:
355       namespaces:
356         count: {{ namespaces_count }}
357         with_serviceaccount: true
358
359   - title: Run a single workload with create/check/delete NodePort service
360     scenario:
361       Kubernetes.create_check_and_delete_pod_with_node_port_service:
362         image: {{ gcr_repo }}/google-samples/hello-go-gke:1.0
363         port: 80
364         protocol: TCP
365         request_timeout: 10
366     runner:
367       constant:
368         concurrency: {{ concurrency }}
369         times: {{ times }}
370     contexts:
371       namespaces:
372         count: {{ namespaces_count }}
373         with_serviceaccount: true