Package org.cdk8s.plus24.k8s
Class IngressRule.Builder
- java.lang.Object
-
- org.cdk8s.plus24.k8s.IngressRule.Builder
-
- All Implemented Interfaces:
software.amazon.jsii.Builder<IngressRule>
- Enclosing interface:
- IngressRule
@Stability(Stable) public static final class IngressRule.Builder extends Object implements software.amazon.jsii.Builder<IngressRule>
A builder forIngressRule
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IngressRule
build()
Builds the configured instance.IngressRule.Builder
host(String host)
Sets the value ofIngressRule.getHost()
IngressRule.Builder
http(HttpIngressRuleValue http)
Sets the value ofIngressRule.getHttp()
-
-
-
Method Detail
-
host
@Stability(Stable) public IngressRule.Builder host(String host)
Sets the value ofIngressRule.getHost()
- Parameters:
host
- Host is the fully qualified domain name of a network host, as defined by RFC 3986. Note the following deviations from the "host" part of the URI as defined in RFC 3986: 1. IPs are not allowed. Currently an IngressRuleValue can only apply to the IP in the Spec of the parent Ingress. 2. The:
delimiter is not respected because ports are not allowed. Currently the port of an Ingress is implicitly :80 for http and :443 for https. Both these may change in the future. Incoming requests are matched against the host before the IngressRuleValue. If the host is unspecified, the Ingress routes all traffic based on the specified IngressRuleValue.Host can be "precise" which is a domain name without the terminating dot of a network host (e.g. "foo.bar.com") or "wildcard", which is a domain name prefixed with a single wildcard label (e.g. ".foo.com"). The wildcard character '' must appear by itself as the first DNS label and matches only a single label. You cannot have a wildcard label by itself (e.g. Host == "*"). Requests will be matched against the Host field in the following way: 1. If Host is precise, the request matches this rule if the http host header is equal to Host. 2. If Host is a wildcard, then the request matches this rule if the http host header is to equal to the suffix (removing the first label) of the wildcard rule.
- Returns:
this
-
http
@Stability(Stable) public IngressRule.Builder http(HttpIngressRuleValue http)
Sets the value ofIngressRule.getHttp()
- Parameters:
http
- the value to be set.- Returns:
this
-
build
@Stability(Stable) public IngressRule build()
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<IngressRule>
- Returns:
- a new instance of
IngressRule
- Throws:
NullPointerException
- if any required attribute was not provided
-
-