Skip to content

Conversation

@TheShubhendra
Copy link

Description

As discussed in #337 and #177, the default CPU request of 500m is excessive—not just for staging environments, but also for some smaller production environments, particularly when multiple replicas are deployed for high availability. To address this, we’ve introduced configurability for CPU and memory resource requests.

Changes:

  • Added cpuRequest and memoryRequest fields to NginxIngressControllerSpec with validation patterns and default values.
  • Propagated these fields to the NginxIngressConfig struct and integrated them into the deployment generation logic.
  • Updated deployment manifests to use the specified resource requests dynamically.

This change allows users to customize CPU and memory resource requests for the NGINX Ingress Controller directly through the CRD.

Fixes #337

Type of change

  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

How Has This Been Tested?

  • Test A

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@TheShubhendra
Copy link
Author

@microsoft-github-policy-service agree

- Added `cpuRequest` and `memoryRequest` fields to NginxIngressControllerSpec with validation and default values.
- Propagated these fields to the NginxIngressConfig struct and deployment generation logic.
- Updated deployment manifests to use the configured resource requests dynamically.

This allows customizable CPU and memory resource requests for the NGINX Ingress Controller via the CRD.
@TheShubhendra TheShubhendra force-pushed the feature/add-resource-request-fields branch from 358ef70 to 142a976 Compare May 24, 2025 12:05
@TheShubhendra TheShubhendra marked this pull request as ready for review May 24, 2025 12:05
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.

Support for Custom Resource Requests and Limits in NginxIngressController

1 participant