Documentation ¶
Index ¶
- Constants
- func GetPodsForDeployment(ctx context.Context, restConfig *rest.Config, deploymentName string, ...) ([]string, error)
- func GetPodsForDeploymentWithPredicate(ctx context.Context, kubeClient *kubernetes.Clientset, ...) ([]string, error)
- func GetPodsForService(ctx context.Context, restConfig *rest.Config, serviceName string, ...) ([]string, error)
- func GetReadyPodsForDeployment(ctx context.Context, kubeClient *kubernetes.Clientset, ...) ([]string, error)
- func GetRestConfigWithKubeContext(kubeContext string) (*rest.Config, error)
- func ServiceFQDN(serviceMeta metav1.ObjectMeta) string
Constants ¶
const ( GlooDeploymentName = "gloo" GlooServiceName = "gloo" // GlooXdsPortName is the name of the port in the Gloo Gateway control plane Kubernetes Service that serves xDS config. // See: install/helm/gloo/templates/2-gloo-service.yaml GlooXdsPortName = "grpc-xds" DiscoveryDeploymentName = "discovery" )
const ( K8sClientQpsEnv = "K8S_CLIENT_QPS" K8sClientQpsDefault = 50 // 10x the k8s-recommended default; gloo gets busy writing status updates K8sClientBurstEnv = "K8S_CLIENT_BURST" K8sClientBurstDefault = 100 // 10x the k8s-recommended default; gloo gets busy writing status updates )
Variables ¶
This section is empty.
Functions ¶
func GetPodsForDeployment ¶
func GetPodsForDeployment( ctx context.Context, restConfig *rest.Config, deploymentName string, deploymentNamespace string, ) ([]string, error)
GetPodsForDeployment gets all pods backing a deployment that are running and ready
func GetPodsForDeploymentWithPredicate ¶
func GetPodsForDeploymentWithPredicate( ctx context.Context, kubeClient *kubernetes.Clientset, deploy metav1.ObjectMeta, predicate func(pod corev1.Pod) bool, ) ([]string, error)
GetPodsForDeploymentWithPredicate gets all pods backing a deployment that are running and satisfy the predicate function
func GetPodsForService ¶
func GetPodsForService( ctx context.Context, restConfig *rest.Config, serviceName string, serviceNamespace string, ) ([]string, error)
GetPodsForService gets all pods backing a deployment
func GetReadyPodsForDeployment ¶
func GetReadyPodsForDeployment( ctx context.Context, kubeClient *kubernetes.Clientset, deploy metav1.ObjectMeta, ) ([]string, error)
GetReadyPodsForDeployment gets all pods backing a deployment that are running and ready This function should be preferred over GetPodsForDeployment
func GetRestConfigWithKubeContext ¶
GetRestConfigWithKubeContext provides the rest.Config object for a given Kubernetes context This is a wrapper on the controller-runtime implementation, and allows overriding certain client properties via environment variables
func ServiceFQDN ¶
func ServiceFQDN(serviceMeta metav1.ObjectMeta) string
ServiceFQDN returns the FQDN for the Service, assuming it is being accessed from within the Cluster https://kubernetes.io/docs/concepts/services-networking/dns-pod-service/#services
Types ¶
This section is empty.