domain

package
v1.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 29, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package domain collects structures and functions around the domains the client works with.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AppDefaultRoute added in v0.0.23

func AppDefaultRoute(ctx context.Context, name, namespace string) (string, error)

AppDefaultRoute constructs and returns an application's default route constructed from the main domain, and the name of the application.

func MainDomain

func MainDomain(ctx context.Context) (string, error)

MainDomain determines the name of the main domain of the currently accessed epinio installation. The result is cached in-memory (see variable mainDomain). The function preferably returns cached data, and queries the cluster ingresses only the first time the data is asked for. This is especially useful for long running commands. In other other words, epinio's API server.

func MatchDo added in v1.1.0

func MatchDo(domain string, domains DomainMap) (string, error)

MatchDo is the core matching function taking a domain and map and returning the secret, or nothing.

Types

type DomainMap added in v1.1.0

type DomainMap map[string]string

domainMap is the internal type for the map from domain patterns to the names of the secrets holding the TLS certs serving them.

func MatchMapLoad added in v1.1.0

func MatchMapLoad(ctx context.Context, namespace string) DomainMap

MatchMapLoad queries the cluster for TLS secrets which are marked for use by epinio, via the routingSelector label. It returns a map from the domains the secrets are serving, to the serving secret.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL