File tree 1 file changed +4
-2
lines changed
server/plugins/kubedeploy
1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -157,7 +157,8 @@ func (x *KubeDeploy) doLoadBalancer(e agent.Event) error {
157
157
IntVal : p .Destination .Port ,
158
158
}
159
159
newPort := v1.ServicePort {
160
- Name : p .Name ,
160
+ // TODO: remove this toLower when we fix the data in mongo, kube only allows lowercase port names
161
+ Name : strings .ToLower (p .Name ),
161
162
Port : p .Source .Port ,
162
163
TargetPort : convPort ,
163
164
Protocol : v1 .Protocol (realProto ),
@@ -198,7 +199,8 @@ func (x *KubeDeploy) doLoadBalancer(e agent.Event) error {
198
199
if svc .Spec .Type == "LoadBalancer" {
199
200
for i := range svc .Spec .Ports {
200
201
for j := range serviceParams .Spec .Ports {
201
- if svc .Spec .Ports [i ].Name == serviceParams .Spec .Ports [j ].Name {
202
+ // TODO: remove this toLower when we fix the data in mongo, kube only allows lowercase port names
203
+ if strings .ToLower (svc .Spec .Ports [i ].Name ) == strings .ToLower (serviceParams .Spec .Ports [j ].Name ) {
202
204
serviceParams .Spec .Ports [j ].NodePort = svc .Spec .Ports [i ].NodePort
203
205
}
204
206
}
You can’t perform that action at this time.
0 commit comments