To support the Istio choose protocol, add the port name to the discovery service. (#27940)
Signed-off-by: Anh Pham <anhpn.uit@gmail.com> Co-authored-by: Anh Pham <anh.pham4@hitachids.com>
This commit is contained in:
parent
305dd5812e
commit
0286e7ad5d
2 changed files with 2 additions and 0 deletions
|
@ -58,6 +58,7 @@ public final class Constants {
|
|||
public static final String KEYCLOAK_SERVICE_PROTOCOL = "TCP";
|
||||
public static final String KEYCLOAK_SERVICE_SUFFIX = "-service";
|
||||
public static final Integer KEYCLOAK_DISCOVERY_SERVICE_PORT = 7800;
|
||||
public static final String KEYCLOAK_DISCOVERY_TCP_PORT_NAME = "tcp";
|
||||
public static final String KEYCLOAK_DISCOVERY_SERVICE_SUFFIX = "-discovery";
|
||||
|
||||
public static final String KEYCLOAK_INGRESS_SUFFIX = "-ingress";
|
||||
|
|
|
@ -48,6 +48,7 @@ public class KeycloakDiscoveryServiceDependentResource extends CRUDKubernetesDep
|
|||
private ServiceSpec getServiceSpec(Keycloak keycloak) {
|
||||
return new ServiceSpecBuilder()
|
||||
.addNewPort()
|
||||
.withName(Constants.KEYCLOAK_DISCOVERY_TCP_PORT_NAME)
|
||||
.withProtocol("TCP")
|
||||
.withPort(Constants.KEYCLOAK_DISCOVERY_SERVICE_PORT)
|
||||
.endPort()
|
||||
|
|
Loading…
Reference in a new issue