The enhancement dynamically adjusts the Gateway's exposure method in an Orchestrator environment based on the operational context—Cloud or Edge—and the presence of an Ingress Controller. In Cloud setups, the Gateway is exposed using a LoadBalancer service, while in Edge environments, it defaults to a NodePort service with a customizable port option. If an Ingress Controller is detected, the Gateway's exposure shifts to ClusterIP, enabling advanced routing and SSL/TLS management through CertManager regardless of instance type.
Type of change
Please delete options that are not relevant.
[x] New feature (non-breaking change which adds functionality)
What has been changed?
This section lists what has been changed with this pull request. Each entry lists the type of change introduced in the following order:
Breaking
Feature
Fix
Doc
Example:
Feature: Middleware can deploy gateway service accordingy to instance type and ingress presence
How Has This Been Tested?
[x] Test A: nodeport was set as below 30000 and above 32767, specifing that ingress is not present, the service nodeport was created with a random nodeport number between 30000 and 32767
[x] Test B: nodeport was set 30000, 31000, 32767, specifing that ingress is not present, the service nodeport was created with correct respectively nodeport.
[x] Test C: when on deployment was specified ingress presence, the service of gateway was deployed with clusterIp
[x] Test D: middleware was deleted and created again specifiing that is Cloud instance type, the service for gateway was created as LoadBalance, ingress was set as is not present, however the service LoadBalance was created with more delay as previous tests.
Checklist:
[x] My code follows the style guidelines of this project
[x] 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
[x] My changes generate no new warnings
[x] I have added tests that prove my fix is effective or that my feature works
[x] New and existing unit tests pass locally with my changes
Description
The enhancement dynamically adjusts the Gateway's exposure method in an Orchestrator environment based on the operational context—Cloud or Edge—and the presence of an Ingress Controller. In Cloud setups, the Gateway is exposed using a LoadBalancer service, while in Edge environments, it defaults to a NodePort service with a customizable port option. If an Ingress Controller is detected, the Gateway's exposure shifts to ClusterIP, enabling advanced routing and SSL/TLS management through CertManager regardless of instance type.
Type of change
Please delete options that are not relevant.
What has been changed?
This section lists what has been changed with this pull request. Each entry lists the type of change introduced in the following order:
Example:
How Has This Been Tested?
Checklist: