Documentation ¶
Overview ¶
Package resources holds simple functions for synthesizing child resources from a Route resource and any relevant Route controller configuration.
Index ¶
- func FilterService(services []*corev1.Service, acceptFilter Filter) []*corev1.Service
- func GetDesiredServiceNames(ctx context.Context, route *v1.Route) (sets.String, error)
- func GetNames(services []*corev1.Service) sets.String
- func IsClusterLocalService(svc *corev1.Service) bool
- func MakeCertificates(route *v1.Route, domainTagMap map[string]string, certClass string) []*networkingv1alpha1.Certificate
- func MakeIngress(ctx context.Context, r *servingv1.Route, tc *traffic.Config, ...) (*v1alpha1.Ingress, error)
- func MakeIngressSpec(ctx context.Context, r *servingv1.Route, tls []v1alpha1.IngressTLS, ...) (v1alpha1.IngressSpec, error)
- func MakeIngressTLS(cert *v1alpha1.Certificate, hostNames []string) v1alpha1.IngressTLS
- func MakeK8sPlaceholderService(ctx context.Context, route *v1.Route, targetName string) (*corev1.Service, error)
- func MakeK8sService(ctx context.Context, route *v1.Route, targetName string, ...) (*corev1.Service, error)
- func SelectorFromRoute(route *v1.Route) labels.Selector
- type Filter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FilterService ¶ added in v0.8.0
FilterService applies a filter to the list of services and return the services that are accepted
func GetDesiredServiceNames ¶ added in v0.8.0
GetDesiredServiceNames returns a list of service names that we expect to create
func IsClusterLocalService ¶ added in v0.8.0
IsClusterLocalService returns whether a service is cluster local.
func MakeCertificates ¶ added in v0.7.0
func MakeCertificates(route *v1.Route, domainTagMap map[string]string, certClass string) []*networkingv1alpha1.Certificate
MakeCertificates creates an array of Certificate for the Route to request TLS certificates. domainTagMap is an one-to-one mapping between domain and tag, for major domain (tag-less), the value is an empty string Returns one certificate for each domain
func MakeIngress ¶ added in v0.8.0
func MakeIngress( ctx context.Context, r *servingv1.Route, tc *traffic.Config, tls []v1alpha1.IngressTLS, ingressClass string, acmeChallenges ...v1alpha1.HTTP01Challenge, ) (*v1alpha1.Ingress, error)
MakeIngress creates Ingress to set up routing rules. Such Ingress specifies which Hosts that it applies to, as well as the routing rules.
func MakeIngressSpec ¶ added in v0.8.0
func MakeIngressSpec( ctx context.Context, r *servingv1.Route, tls []v1alpha1.IngressTLS, targets map[string]traffic.RevisionTargets, visibility map[string]netv1alpha1.IngressVisibility, acmeChallenges ...v1alpha1.HTTP01Challenge, ) (v1alpha1.IngressSpec, error)
MakeIngressSpec creates a new IngressSpec
func MakeIngressTLS ¶ added in v0.7.0
func MakeIngressTLS(cert *v1alpha1.Certificate, hostNames []string) v1alpha1.IngressTLS
MakeIngressTLS creates IngressTLS to configure the ingress TLS.
func MakeK8sPlaceholderService ¶
func MakeK8sPlaceholderService(ctx context.Context, route *v1.Route, targetName string) (*corev1.Service, error)
MakeK8sPlaceholderService creates a placeholder Service to prevent naming collisions. It's owned by the provided v1.Route. The purpose of this service is to provide a placeholder domain name for Istio routing.
func MakeK8sService ¶
func MakeK8sService(ctx context.Context, route *v1.Route, targetName string, ingress *netv1alpha1.Ingress, isPrivate bool) (*corev1.Service, error)
MakeK8sService creates a Service that redirect to the loadbalancer specified in Ingress status. It's owned by the provided v1.Route. The purpose of this service is to provide a domain name for Istio routing.
Types ¶
Directories ¶
Path | Synopsis |
---|---|
Package labels holds simple functions for working with ObjectMeta labels.
|
Package labels holds simple functions for working with ObjectMeta labels. |
Package names holds simple functions for synthesizing resource names.
|
Package names holds simple functions for synthesizing resource names. |