File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -358,8 +358,6 @@ func (b *StorageStatefulSetBuilder) buildCaStorePatchingInitContainerVolumeMount
358
358
359
359
func (b * StorageStatefulSetBuilder ) buildContainerPorts () []corev1.ContainerPort {
360
360
podPorts := []corev1.ContainerPort {{
361
- Name : "grpc" , ContainerPort : api .GRPCPort ,
362
- }, {
363
361
Name : "interconnect" , ContainerPort : api .InterconnectPort ,
364
362
}, {
365
363
Name : "status" , ContainerPort : api .StatusPort ,
@@ -414,11 +412,16 @@ func (b *StorageStatefulSetBuilder) buildContainer() corev1.Container { // todo
414
412
Resources : containerResources ,
415
413
}
416
414
415
+ livenessProbePort := api .GRPCPort
416
+ if b .Spec .Service .GRPC .Port != 0 {
417
+ livenessProbePort = int (b .Spec .Service .GRPC .Port )
418
+ }
419
+
417
420
if value , ok := b .ObjectMeta .Annotations [api .AnnotationDisableLivenessProbe ]; ! ok || value != api .AnnotationValueTrue {
418
421
container .LivenessProbe = & corev1.Probe {
419
422
ProbeHandler : corev1.ProbeHandler {
420
423
TCPSocket : & corev1.TCPSocketAction {
421
- Port : intstr .FromInt (api . GRPCPort ),
424
+ Port : intstr .FromInt (livenessProbePort ),
422
425
},
423
426
},
424
427
}
You can’t perform that action at this time.
0 commit comments