Documentation
¶
Index ¶
- Variables
- func AreIPsInSameSubnet(ip1, ip2, subnet string) bool
- func AssertEventually(check func() error, timeout, interval, additional_timeout time.Duration, ...)
- func BuildAndPush(ctx context.Context, dockerfilePath string, image ContainerImage) error
- func BuildContainer(ctx context.Context, dockerfilePath string, tag string) error
- func ConfigureDpuOperator(c client.Client, configFile string) error
- func CreateClientsFromConfig(restConfig *rest.Config) (client.Client, kubernetes.Interface, error)
- func CreateDpuOperatorCR(client client.Client, cr *configv1.DpuOperatorConfig)
- func CreateDpuOperatorCRWithRetry(client client.Client, cr *configv1.DpuOperatorConfig) error
- func CreateNamespace(client client.Client, ns *corev1.Namespace)
- func CreateNamespaceWithRetry(client client.Client, ns *corev1.Namespace) error
- func DeleteAndEventuallyPodDoesNotExist(c client.Client, podName string, podNamespace string, timeout time.Duration, ...)
- func DeleteDpuOperatorCR(client client.Client, cr *configv1.DpuOperatorConfig)
- func DeleteNamespace(client client.Client, ns *corev1.Namespace)
- func DpuOperatorCR(name string, ns *corev1.Namespace) *configv1.DpuOperatorConfig
- func DpuOperatorNamespace() *corev1.Namespace
- func EnsurePullAndPush(ctx context.Context, sourceImage, targetImage ContainerImage) error
- func EventuallyDpuOperatorConfigReady(c client.Client, logger logr.Logger, cr *configv1.DpuOperatorConfig, ...) *configv1.DpuOperatorConfig
- func EventuallyNoDpuOperatorConfig(c client.Client, timeout time.Duration, interval time.Duration)
- func EventuallyPodDoesNotExist(c client.Client, podName string, podNamespace string, timeout time.Duration, ...)
- func EventuallyPodIsRunning(c client.Client, podName string, podNamespace string, timeout time.Duration, ...) *corev1.Pod
- func ExecInPod(clientset kubernetes.Interface, config *rest.Config, pod *corev1.Pod, ...) (string, error)
- func GenerateAvailableIP(subnet string, usedIPs map[string]bool) string
- func GetDPUHostNodes(c client.Client) ([]corev1.Node, error)
- func GetDPUNodes(c client.Client) ([]corev1.Node, error)
- func GetDpuOperatorConfig(c client.Client, name string) *configv1.DpuOperatorConfig
- func GetFirstNode(c client.Client) (corev1.Node, error)
- func GetGatewayFromSubnet(subnet string) string
- func GetPod(c client.Client, name string, namespace string) *corev1.Pod
- func GetPodEvents(c client.Client, podName string, podNamespace string) string
- func GetSecondaryNetworkIP(pod *corev1.Pod, netdevName string) (string, error)
- func GetSubnet(ip string) string
- func IsDpuOperatorConfigReady(c client.Client, name string) error
- func IsMasterNode(node corev1.Node) bool
- func LabelAllNodesWithDpu(c client.Client) error
- func LabelNodesForDpu(c client.Client, dpuSide string) error
- func LabelNodesWithDpu(c client.Client) error
- func LabelSingleNodeWithDpu(c client.Client, node *corev1.Node) error
- func LabelWorkerNodesWithDpu(c client.Client) error
- func LogDpuOperatorConfigDiagnostics(c client.Client, name string) string
- func LogPodDiagnostics(c client.Client, podName string, podNamespace string) string
- func NewTestPod(podName string, nodeHostname string) *corev1.Pod
- func NewTestSfc(sfcName string, nfName string) *configv1.ServiceFunctionChain
- func PodGetDpuResourceRequests(pod *corev1.Pod) int
- func PodIsRunning(c client.Client, podName string, podNamespace string) bool
- func PullContainer(ctx context.Context, imageRef string, arch string, tag string) error
- func PushContainer(ctx context.Context, imageRef string) error
- func RemoteImageExists(ctx context.Context, image ContainerImage) (bool, error)
- func SetDpuOperatorConfigReady(c client.Client, name string)
- func SetupDpuOperator(c client.Client, configFile string) error
- func SetupDpuOperatorConfig(c client.Client, configFile string) error
- func SetupDpuOperatorWithRetry(c client.Client, configFile string) error
- func SfcCreate(c client.Client, sfc *configv1.ServiceFunctionChain) *configv1.ServiceFunctionChain
- func SfcGet(c client.Client, name string, namespace string) *configv1.ServiceFunctionChain
- func SfcList(c client.Client, namespace string) *configv1.ServiceFunctionChainList
- func SfcNew(namespace, sfcName, nfName, nfImage string) *configv1.ServiceFunctionChain
- func SfcWait(c client.Client, name, namespace string, timeout time.Duration) *configv1.ServiceFunctionChain
- func TrafficFlowTestsImage() string
- func TryEventually(check func() error, timeout, interval time.Duration) error
- func WaitAllNodesReady(client client.Client)
- func WaitForAllPodsReady(c client.Client, namespace string) error
- func WaitForDPU(c client.Client) error
- func WaitForDPUReady(c client.Client) error
- func WaitForDaemonSetReady(daemonSet *appsv1.DaemonSet, k8sClient client.Client, namespace, name string)
- type CdaCluster
- type Cluster
- type ContainerImage
- type KindCluster
- type NetworkStatus
Constants ¶
This section is empty.
Variables ¶
View Source
var ( TestAPITimeout = time.Second * 10 TestRetryInterval = time.Millisecond * 10 TestInitialSetupTimeout = time.Minute )
Functions ¶
func AreIPsInSameSubnet ¶
func AssertEventually ¶
func BuildAndPush ¶
func BuildAndPush(ctx context.Context, dockerfilePath string, image ContainerImage) error
func BuildContainer ¶
func CreateClientsFromConfig ¶
func CreateDpuOperatorCR ¶
func CreateDpuOperatorCR(client client.Client, cr *configv1.DpuOperatorConfig)
func CreateDpuOperatorCRWithRetry ¶
func CreateDpuOperatorCRWithRetry(client client.Client, cr *configv1.DpuOperatorConfig) error
func DeleteDpuOperatorCR ¶
func DeleteDpuOperatorCR(client client.Client, cr *configv1.DpuOperatorConfig)
func DpuOperatorCR ¶
func DpuOperatorCR(name string, ns *corev1.Namespace) *configv1.DpuOperatorConfig
func DpuOperatorNamespace ¶
func EnsurePullAndPush ¶
func EnsurePullAndPush(ctx context.Context, sourceImage, targetImage ContainerImage) error
func EventuallyPodIsRunning ¶
func GetDpuOperatorConfig ¶
func GetDpuOperatorConfig(c client.Client, name string) *configv1.DpuOperatorConfig
func GetGatewayFromSubnet ¶
Assume a standard /24 subnet for simplicity
func GetSecondaryNetworkIP ¶
func IsMasterNode ¶
func LabelAllNodesWithDpu ¶
func LabelNodesWithDpu ¶
func LabelWorkerNodesWithDpu ¶
func LogPodDiagnostics ¶
func NewTestSfc ¶
func NewTestSfc(sfcName string, nfName string) *configv1.ServiceFunctionChain
func PullContainer ¶
func RemoteImageExists ¶
func RemoteImageExists(ctx context.Context, image ContainerImage) (bool, error)
func SfcCreate ¶
func SfcCreate(c client.Client, sfc *configv1.ServiceFunctionChain) *configv1.ServiceFunctionChain
func SfcNew ¶
func SfcNew(namespace, sfcName, nfName, nfImage string) *configv1.ServiceFunctionChain
func TrafficFlowTestsImage ¶
func TrafficFlowTestsImage() string
TrafficFlowTestsImage returns the appropriate image reference based on USE_LOCAL_REGISTRY
func WaitAllNodesReady ¶
func WaitForDPU ¶
func WaitForDPUReady ¶
Types ¶
type CdaCluster ¶
func (*CdaCluster) EnsureExists ¶
func (t *CdaCluster) EnsureExists(kubeconfigPath string) (*rest.Config, error)
type ContainerImage ¶
func (ContainerImage) FullRef ¶
func (ci ContainerImage) FullRef() string
func (ContainerImage) LocalRef ¶
func (ci ContainerImage) LocalRef() string
type KindCluster ¶
type KindCluster struct {
Name string
}
func (*KindCluster) EnsureDeleted ¶
func (t *KindCluster) EnsureDeleted()
func (*KindCluster) EnsureExists ¶
func (t *KindCluster) EnsureExists() *rest.Config
func (*KindCluster) TempDirPath ¶
func (t *KindCluster) TempDirPath() string
Click to show internal directories.
Click to hide internal directories.