kubernetesk8s.io/kubernetes/test/e2e/framework/registry Index | Files

package registry

import "k8s.io/kubernetes/test/e2e/framework/registry"

Index

Functions

func SetupRegistry

func SetupRegistry(ctx context.Context, f *framework.Framework, podOnly bool) (string, []string, error)

SetupRegistry runs the `fake-registry-server --private` from the agnhost image. The registry is run with HostPort 5000 exposed in order to allow locally-scheduled pods to query the registry via kubelet. The registry only runs in HTTP (no TLS) mode, and so this hack-path is used as localhost is typically allowed by CRIs and so no CRI-specific configuration is needed

By default, the function runs the registry as a DaemonSet on all nodes, but it supports running it in just a `pod` for cases where kube-controller-manager is not running (like in the Node Conformance test suite).

This function returns: - the node-local address of the registry - set of node names that the registry runs on, mostly useful only in the podOnly case - an error

TODO: once https://github.com/kubernetes/kubernetes/issues/132955 is addressed, we might be able to proxy a single endpoint from the cluster to each node's localhost port instead of using DaemonSets.

func User1DockerSecret

func User1DockerSecret(registryAddress string) *v1.Secret

User1DockerSecret creates a secret containing the docker credentials for pulling from the agnhost fake-registry-server.

Source Files

registry.go

Version
v1.36.0 (latest)
Published
Apr 22, 2026
Platform
linux/amd64
Imports
13 packages
Last checked
5 seconds ago

Tools for package owners.