Skip to content

Commit 14c1693

Browse files
dry923aakarshg
authored andcommitted
Adding optional image location for workloads
1 parent 523cf19 commit 14c1693

File tree

16 files changed

+53
-27
lines changed

16 files changed

+53
-27
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
# Ignore
2+
*.swp

README.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,33 @@ un-block it. The benchmarks mentioned above that state `Used` for Reconciliation
3333
These two bencharmks are written in a way that doesn't allow for reconciliation to be implemented. To take
3434
advantage of the reconciliation loop, these two benchmarks need to be rewritten.
3535

36+
## Optional workload images
37+
Optional locations for workload images can now be added easily without the need to rebuild the operator.
38+
To do so in the workload args section of the CR add image: [location]
39+
40+
NOTE: This is not a required arguement. If omitted it will default to the currently verified workload image.
41+
Additionally, this is not enabled for YCSB
42+
43+
For Example:
44+
45+
```
46+
apiVersion: ripsaw.cloudbulldozer.io/v1alpha1
47+
kind: Benchmark
48+
metadata:
49+
name: example-benchmark
50+
namespace: my-ripsaw
51+
spec:
52+
elasticsearch:
53+
server: "my-es.foo.bar"
54+
port: 9200
55+
metadata_collection: true
56+
cleanup: false
57+
workload:
58+
name: "foo"
59+
args:
60+
image: my.location/foo:latest
61+
```
62+
3663
## Installation
3764
[Installation](docs/installation.md)
3865

roles/backpack/templates/backpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ spec:
2222
effect: NoSchedule
2323
containers:
2424
- name: backpack
25-
image: quay.io/cloud-bulldozer/backpack:latest
25+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
2626
command: ["/bin/sh", "-c"]
2727
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name; sleep infinity"]
2828
imagePullPolicy: Always

roles/byowl/templates/workload.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ spec:
2222
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
2323
initContainers:
2424
- name: backpack-{{ trunc_uuid }}
25-
image: quay.io/cloud-bulldozer/backpack:latest
25+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
2626
command: ["/bin/sh", "-c"]
2727
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
2828
imagePullPolicy: Always

roles/fio-distributed/templates/client.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ spec:
1313
spec:
1414
containers:
1515
- name: fio-client
16-
image: "quay.io/cloud-bulldozer/fio:latest"
16+
image: {{ fiod.image | default('quay.io/cloud-bulldozer/fio:latest') }}
1717
imagePullPolicy: Always
1818
wait: true
1919
env:
@@ -72,7 +72,7 @@ spec:
7272
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
7373
initContainers:
7474
- name: backpack-{{ trunc_uuid }}
75-
image: quay.io/cloud-bulldozer/backpack:latest
75+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
7676
command: ["/bin/sh", "-c"]
7777
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
7878
imagePullPolicy: Always

roles/fio-distributed/templates/servers.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ spec:
2929
securityContext:
3030
privileged: true
3131
{% endif %}
32-
image: "quay.io/cloud-bulldozer/fio:latest"
32+
image: {{ fiod.image | default('quay.io/cloud-bulldozer/fio:latest') }}
3333
imagePullPolicy: Always
3434
ports:
3535
- containerPort: 8765
@@ -63,7 +63,7 @@ spec:
6363
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
6464
initContainers:
6565
- name: backpack-{{ trunc_uuid }}
66-
image: quay.io/cloud-bulldozer/backpack:latest
66+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
6767
command: ["/bin/sh", "-c"]
6868
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
6969
imagePullPolicy: Always

roles/fs-drift/templates/workload_job.yml.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ spec:
3131
securityContext:
3232
privileged: true
3333
{% endif %}
34-
image: quay.io/cloud-bulldozer/fs-drift:master
34+
image: {{ fs_drift.image | default('quay.io/cloud-bulldozer/fs-drift:master') }}
3535
# example of what to do when debugging image
3636
# image: quay.io/bengland2/fs-drift:latest
3737
imagePullPolicy: Always
@@ -97,7 +97,7 @@ spec:
9797
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
9898
initContainers:
9999
- name: backpack-{{ trunc_uuid }}
100-
image: quay.io/cloud-bulldozer/backpack:latest
100+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
101101
command: ["/bin/sh", "-c"]
102102
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
103103
imagePullPolicy: Always

roles/hammerdb/templates/db_creation.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ spec:
1616
- name: hammerdb
1717
command: ["/bin/sh", "-c"]
1818
args: ["/usr/local/bin/uid_entrypoint; cd /hammer; ./hammerdbcli auto /creator/createdb.tcl"]
19-
image: "quay.io/cloud-bulldozer/hammerdb:latest"
19+
image: {{ hammerdb.image | default('quay.io/cloud-bulldozer/hammerdb:latest') }}
2020
imagePullPolicy: Always
2121
volumeMounts:
2222
- name: hammerdb-creator-volume
@@ -31,7 +31,7 @@ spec:
3131
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
3232
initContainers:
3333
- name: backpack-{{ trunc_uuid }}
34-
image: quay.io/cloud-bulldozer/backpack:latest
34+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
3535
command: ["/bin/sh", "-c"]
3636
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
3737
imagePullPolicy: Always

roles/hammerdb/templates/db_workload.yml.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ spec:
1313
spec:
1414
containers:
1515
- name: hammerdb
16-
image: "quay.io/cloud-bulldozer/hammerdb:master"
16+
image: {{ hammerdb.image | default('quay.io/cloud-bulldozer/hammerdb:master') }}
1717
imagePullPolicy: Always
1818
wait: true
1919
command: ["/bin/sh", "-c"]
@@ -54,7 +54,7 @@ spec:
5454
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
5555
initContainers:
5656
- name: backpack-{{ trunc_uuid }}
57-
image: quay.io/cloud-bulldozer/backpack:latest
57+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
5858
command: ["/bin/sh", "-c"]
5959
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
6060
imagePullPolicy: Always

roles/iperf3-bench/templates/client.yml.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ spec:
2020
{% endif %}
2121
containers:
2222
- name: benchmark
23-
image: "quay.io/cloud-bulldozer/iperf3:latest"
23+
image: {{ iperf3.image | default('quay.io/cloud-bulldozer/iperf3:latest') }}
2424
imagePullPolicy: Always
2525
wait: true
2626
command: ["/bin/sh", "-c"]
@@ -34,7 +34,7 @@ spec:
3434
{% if metadata_collection|default(false) is sameas true and metadata_targeted|default(true) is sameas true %}
3535
initContainers:
3636
- name: backpack-{{ trunc_uuid }}
37-
image: quay.io/cloud-bulldozer/backpack:latest
37+
image: {{ metadata_image | default('quay.io/cloud-bulldozer/backpack:latest') }}
3838
command: ["/bin/sh", "-c"]
3939
args: ["python3 stockpile-wrapper.py -s {{ elasticsearch.server }} -p {{ elasticsearch.port }} -u {{ uuid }} -n $my_node_name -N $my_pod_name"]
4040
imagePullPolicy: Always

0 commit comments

Comments
 (0)