Skip to content

Commit 447dacd

Browse files
eshulman2claude
andcommitted
[shiftstack] Make shiftstackclient pod resources configurable
Add variables to configure CPU and memory requests/limits for the shiftstackclient pod instead of hardcoding them. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> Signed-off-by: Ella Shulman <eshulman@redhat.com>
1 parent 009f32f commit 447dacd

File tree

4 files changed

+12
-6
lines changed

4 files changed

+12
-6
lines changed

roles/shiftstack/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ Role for triggering Openshift on Openstack QA automation (installation and tests
2525
* `cifmw_shiftstack_sc`: (*string*) The storage class to be used for PVC for the shiftstackclient pod. Defaults to `local-storage`.
2626
* `cifmw_shiftstack_shiftstackclient_artifacts_dir`: (*string*) The artifacts directory path for the shiftstackclient pod. Defaults to `/home/cloud-admin/artifacts`.
2727
* `cifmw_shiftstack_shiftstackclient_incluster_kubeconfig_dir`: (*string*) The directory path in shiftstackclient pod the will hold the RHOSO kubeconfig. Defaults to `/home/cloud-admin/incluster-kubeconfig`.
28+
* `cifmw_shiftstack_client_pod_ram_requests`: (*string*) Memory request for the shiftstackclient pod. Defaults to `12Gi`.
29+
* `cifmw_shiftstack_client_pod_ram_limits`: (*string*) Memory limit for the shiftstackclient pod. Defaults to `12Gi`.
30+
* `cifmw_shiftstack_client_pod_cpu_requests`: (*string*) CPU request for the shiftstackclient pod. Defaults to `4`.
31+
* `cifmw_shiftstack_client_pod_cpu_limits`: (*string*) CPU limit for the shiftstackclient pod. Defaults to `4`.
2832

2933
## Examples
3034
The role is imported in the test playbook, i.e. when:

roles/shiftstack/defaults/main.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,3 +40,7 @@ cifmw_shiftstack_sc: "local-storage"
4040
cifmw_shiftstack_shiftstackclient_artifacts_dir: "/home/cloud-admin/artifacts"
4141
cifmw_shiftstack_shiftstackclient_installation_dir: "{{ cifmw_shiftstack_shiftstackclient_artifacts_dir }}/installation"
4242
cifmw_shiftstack_shiftstackclient_incluster_kubeconfig_dir: "/home/cloud-admin/incluster-kubeconfig"
43+
cifmw_shiftstack_client_pod_ram_requests: "12Gi"
44+
cifmw_shiftstack_client_pod_ram_limits: "12Gi"
45+
cifmw_shiftstack_client_pod_cpu_requests: "4"
46+
cifmw_shiftstack_client_pod_cpu_limits: "4"

roles/shiftstack/templates/shiftstackclient_pod.yml.j2

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@ spec:
1818
{% else %}
1919
resources:
2020
requests:
21-
memory: "12Gi"
22-
cpu: "4"
21+
memory: "{{ cifmw_shiftstack_client_pod_ram_requests }}"
22+
cpu: "{{ cifmw_shiftstack_client_pod_cpu_requests }}"
2323
limits:
24-
memory: "12Gi"
25-
cpu: "4"
24+
memory: "{{ cifmw_shiftstack_client_pod_ram_limits }}"
25+
cpu: "{{ cifmw_shiftstack_client_pod_cpu_limits }}"
2626
{% endif %}
2727
securityContext:
2828
privileged: true

roles/shiftstack/templates/shiftstackclient_pvc.yml.j2

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ spec:
77
storageClassName: {{ cifmw_shiftstack_sc }}
88
accessModes:
99
- ReadWriteOnce
10-
- ReadWriteMany
11-
- ReadOnlyMany
1210
resources:
1311
requests:
1412
storage: 2Gi

0 commit comments

Comments
 (0)