Watch Aspire live streamsDocsTry Aspire

withHostname

Method
📦 Aspire.Hosting.Kubernetes v13.6.0-preview.1.26478.8
interface KubernetesIngressResource {
// ... omitted for brevity
withHostname(hostname: string): KubernetesIngressResource;
}

Signature

methodwithHostnamebuilder
Adds a hostname that this ingress matches. Multiple hostnames can be added by calling this method repeatedly. Path rules without an explicit host apply to each configured hostname. If no hostnames are configured, those rules match all hosts.
withHostname(hostname: string): KubernetesIngressResource
hostnamestring
KubernetesIngressResource

Applies to

This method applies to the following types: