Documentation ¶
Index ¶
Examples ¶
Constants ¶
View Source
const (
// NamespaceEnvKey is the environment variable that holds kf's namespace.
NamespaceEnvKey = "SYSTEM_NAMESPACE"
)
Variables ¶
This section is empty.
Functions ¶
func ClusterIngressSelector ¶
ClusterIngressSelector matches the set of labels expected to select the cluster ingress. This matches the selector found in config/202-external-gateway.yaml.
func ExtractProxyIngressFromList ¶
func ExtractProxyIngressFromList(ingresses []corev1.LoadBalancerIngress) (string, error)
ExtractProxyIngressFromList is a utility function that extracts a single routable ingress from the list.
func GetClusterIngresses ¶
func GetClusterIngresses(lister ServiceLister) ([]corev1.LoadBalancerIngress, error)
GetClusterIngresses extracts LoadBalancerIngresses from the services matching the ClusterIngressSelector.
func Namespace ¶
func Namespace() string
Namespace holds the K8s namespace where our serving system components run.
Example ¶
package main import ( "fmt" "github.com/google/kf/v2/pkg/system" _ "github.com/google/kf/v2/pkg/system/testing" ) func main() { fmt.Println(system.Namespace()) }
Output: kf-testing
Types ¶
Click to show internal directories.
Click to hide internal directories.