MC chart load balancer ip (#5048)

adding loadBalancerIP to linkerd2-multicluster chart

Sometimes you are in need to tell the gateway service to pick up / request a specific IP from the LB.
e.g. when you talk to another cluster that is having another firewall in front and not permitting access from random IPs.

Solution
Minor change in the chart for Multicluster.

Validation
Example in a GKE:
Register a static IP, note it. Then

helm install linkerd-mc linkerd2/linkerd2-multicluster --set loadBalancerIP="<IP>"

Your gateway service will come up with the IP you have given it.
If you don't set the parameter, then the LB will give out a random IP.

If you don't have a cluster, look at the yaml produced by helm template...
and look if the loadBalancerIP: <IP>  is there

```
`apiVersion: v1
kind: Service
.
.
.
  selector:
    app: linkerd-gateway
  type: LoadBalancer
  loadBalancerIP: 1.1.1.1`
```

Signed-off-by: Markus Bettsteller <markus@bettsteller.de>
This commit is contained in:
Markus 2020-10-13 17:08:40 +02:00 committed by GitHub
parent 41c1fc65b0
commit f8e7295bdc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View File

@ -38,3 +38,4 @@ linkerd2-multicluster chart and their default values.
|`logLevel` | Log level for the Multicluster components |`info` |
|`serviceMirrorRetryLimit` | Number of times update from the remote cluster is allowed to be requeued (retried) |`3` |
|`serviceMirrorUID` | User id under which the Service Mirror shall be ran |`2103` |
|`loadBalancerIP` | Request a specific IP address for the gateway service (e.g. use an IP address you have reserved) |emptyString |

View File

@ -133,6 +133,9 @@ spec:
selector:
app: {{.Values.gatewayName}}
type: LoadBalancer
{{- if .Values.loadBalancerIP }}
loadBalancerIP: {{ .Values.loadBalancerIP }}
{{- end }}
---
kind: ServiceAccount
apiVersion: v1