jameskelleher opened a new pull request, #9494:
URL: https://github.com/apache/pinot/pull/9494

   The primary purpose of this PR is to [add support 
for](https://github.com/apache/pinot/issues/9438) `loadBalancerSourceRanges` 
(which already exists in `values.yaml`) to the `service-external.yaml` 
templates for the controller and the broker. This allows the developer to 
specify which IP addresses they'd like to permit controller/broker access.
   
   Additionally, I changed some template file suffixes from `.yml` to `.yaml`, 
to a) match internal consistency and b) adhere to Helm's recommendations.
   
   # Testing
   I tested the changes by running `helm install --dry-run --debug pinot 
./kubernetes/helm/pinot`. For each test, I provide what I set 
`loadBalancerSourceRanges` to in `values.yaml`, as well as the templated result 
for `service-external.yaml`. 
   
   ## Test 1: Empty source range list
   ```yaml
   # values.yaml
   loadBalancerSourceRanges: []
   ```
   
   ```yaml
   # Source: pinot/templates/controller/service-external.yaml
   apiVersion: v1
   kind: Service
   metadata:
     name: pinot-controller-external
     annotations:
       {}
     labels:
       helm.sh/chart: pinot-0.2.6-SNAPSHOT
       app: pinot
       release: pinot
       app.kubernetes.io/version: "0.2.6-SNAPSHOT"
       app.kubernetes.io/managed-by: Helm
       heritage: Helm
       component: controller
   spec:
     type: LoadBalancer
     ports:
       - name: external-controller
         port: 9000
     selector:
       app: pinot
       release: pinot
       component: controller
     loadBalancerSourceRanges:
           []
   ```
   
   ```yaml
   # Source: pinot/templates/broker/service-external.yaml
   apiVersion: v1
   kind: Service
   metadata:
     name: pinot-broker-external
     annotations:
           {}
     labels:
       helm.sh/chart: pinot-0.2.6-SNAPSHOT
       app: pinot
       release: pinot
       app.kubernetes.io/version: "0.2.6-SNAPSHOT"
       app.kubernetes.io/managed-by: Helm
       heritage: Helm
       component: broker
   spec:
     type: LoadBalancer
     ports:
       - name: external-broker
         port: 8099
     selector:
       app: pinot
       release: pinot
       component: broker
     loadBalancerSourceRanges:
           []
   ```
   ## Test 2: Non-empty list
   ```yaml
   # values.yaml
   loadBalancerSourceRanges:
       - 127.0.0.1/32
       - 123.4.5.6/24
   ```
   
   ```yaml
   # Source: pinot/templates/controller/service-external.yaml
   apiVersion: v1
   kind: Service
   metadata:
     name: pinot-controller-external
     annotations:
       {}
     labels:
       helm.sh/chart: pinot-0.2.6-SNAPSHOT
       app: pinot
       release: pinot
       app.kubernetes.io/version: "0.2.6-SNAPSHOT"
       app.kubernetes.io/managed-by: Helm
       heritage: Helm
       component: controller
   spec:
     type: LoadBalancer
     ports:
       - name: external-controller
         port: 9000
     selector:
       app: pinot
       release: pinot
       component: controller
     loadBalancerSourceRanges:
       - 127.0.0.1/32
       - 123.4.5.6/24
   ```
   
   ```yaml
   # Source: pinot/templates/broker/service-external.yaml
   apiVersion: v1
   kind: Service
   metadata:
     name: pinot-broker-external
     annotations:
       {}
     labels:
       helm.sh/chart: pinot-0.2.6-SNAPSHOT
       app: pinot
       release: pinot
       app.kubernetes.io/version: "0.2.6-SNAPSHOT"
       app.kubernetes.io/managed-by: Helm
       heritage: Helm
       component: broker
   spec:
     type: LoadBalancer
     ports:
       - name: external-broker
         port: 8099
     selector:
       app: pinot
       release: pinot
       component: broker
     loadBalancerSourceRanges:
       - 127.0.0.1/32
       - 123.4.5.6/24
   ```
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to