Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option for operator to set resource claims on daemonset containers #848

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

staerion
Copy link

@staerion staerion commented Aug 2, 2023

Change description

Add option for operator to set resource claims on daemonset containers

The operator installation of trident currently does not allow setting resource requests and limits for the daemonset containers. With this change the option is added through the TridentOrchestrator crd to set specific resource requests and limits. If no resource requests or limits are set, the current default values are respected.

Project tracking

N/A

Do any added TODOs have an issue in the backlog?

No

Did you add unit tests? Why not?

Added unit tests for the construction of the resource yaml fields.

Does this code need functional testing?

No

Is a code review walkthrough needed? why or why not?

I hope the MR is quite straight forward but I'm open for a walkthrough if it helps to get this MR through.

Should additional test coverage be executed in addition to pre-merge?

No

Does this code need a note in the changelog?

Yes, two extra fields have been added to the tridentorchestrator crd:

apiVersion: trident.netapp.io/v1
kind: TridentOrchestrator
spec:
  dsRegistrarResources: {}
  dsTridentResources: {}

The old default values are being respected when these fields are not set. In case they are set, they will configure the trident daemonset according to the corev1 resourceRequirements field.

Does this code require documentation changes?

No

Additional Information

Currently we're using the trident operator install on a cluster with about ~90 nodes. The trident-node-linux daemonset that the operator generates does not have any resources requests / limits specified. Because of this the pods inherit the resources requests / limits that the are being set by the limitrange object from our rancher setup. This results both in way too many resources being claimed. With this MR we hope to get some more control over the daemonset this is being generated by the operator.

@staerion staerion force-pushed the allow-to-set-resource-request-limits-through-operator branch 6 times, most recently from cffa741 to 3882803 Compare August 3, 2023 13:28
@staerion staerion force-pushed the allow-to-set-resource-request-limits-through-operator branch from 3882803 to 6b8457d Compare August 3, 2023 13:30
@staerion staerion changed the title add option for operator to set resource claims on daemonset containers Add option for operator to set resource claims on daemonset containers Aug 3, 2023
@staerion staerion marked this pull request as ready for review August 3, 2023 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant