| Modifier and Type | Interface and Description |
|---|---|
static class |
ServiceExposer.Util |
| Modifier and Type | Field and Description |
|---|---|
static String |
EXPOSE_LABEL
This label was originally consumed by the the deprecated
Expose controller.
|
INTERNAL_ANNOTATION_PREFIX| Modifier and Type | Method and Description |
|---|---|
default boolean |
canExposeService(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
Services with the following properties will be automatically exposed:
Exposure of a single port
Are not labeled expose: false
Not part of the Kubernetes System (?? legacy from IngressEnricher)
|
default Set<Integer> |
getPorts(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
Returns a Set of ports exposed by the Service.
|
default boolean |
hasWebPorts(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
Returns true if the Service exposes a 'web' port.
|
default boolean |
isExposedWithLabel(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
Returns true if the Service has a
metadata.label with the key 'expose' and the value 'true'. |
create, enrich, getContextstatic final String EXPOSE_LABEL
It is now used to prevent a Service from being exposed.
default Set<Integer> getPorts(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
serviceBuilder - the Service to get the ports from.default boolean hasWebPorts(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
serviceBuilder - the ServiceBuilder to check the ports from.default boolean canExposeService(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
serviceBuilder - the ServiceBuilder to check the ports from.default boolean isExposedWithLabel(io.fabric8.kubernetes.api.model.ServiceBuilder serviceBuilder)
metadata.label with the key 'expose' and the value 'true'.
n.b. This label should be provided by a fragment or the jkube.enricher.jkube-service.expose configuration. Using the MetadataEnricher will add the label after the Service has been processed by the ServiceExposer(s).
serviceBuilder - the Service to check the label from.Copyright © 2023. All rights reserved.