Documentation ¶
Index ¶
- Constants
- func DockerCredentialsDefined() bool
- func DumpClusterInfo(path string, namespace string)
- func GetKubeconfig(createDefault bool) string
- func WaitForOutput(k KCmd, expected string, seconds int) error
- func WaitForOutputContains(k KCmd, expected string, seconds int) error
- func WaitForOutputPattern(k KCmd, pattern string, seconds int) error
- func WatchPods()
- func WatchPodsInNs(namespace string)
- type KCmd
- func Annotate(resource string, name string, key string, value string) KCmd
- func ApplyFiles(paths ...string) KCmd
- func ClusterInfoForContext(ctxt string) KCmd
- func CreateFromFiles(paths ...string) KCmd
- func CreateNamespace(namespace string) KCmd
- func CreateSecretLiteral(name string, user string, pw string) KCmd
- func Delete(args ...string) KCmd
- func DeleteByTypeAndName(resourceType string, names ...string) KCmd
- func DeleteFromFiles(paths ...string) KCmd
- func DeleteNamespace(namespace string) KCmd
- func Describe(args ...string) KCmd
- func DumpAllLogs(path string) KCmd
- func DumpLogs(path string, namespace string) KCmd
- func ExecOnPod(podName string, args ...string) KCmd
- func Get(args ...string) KCmd
- func GetByFiles(paths ...string) KCmd
- func GetByTypeAndName(resourceType string, names ...string) KCmd
- func GetNodeNameForPod(podName string) KCmd
- func GetNodes() KCmd
- func Label(nodes string, key string, value string) KCmd
- func Logs(args ...string) KCmd
- func Patch(resource string, data string) KCmd
- func PatchJson(resource string, data string) KCmd
- func PatchMerge(resource string, data string) KCmd
- func Taint(node string, key string, value string, effect string) KCmd
- func (k KCmd) ExecV() error
- func (k KCmd) ExecVCapture() (string, string, error)
- func (k KCmd) ExecVPanic()
- func (k KCmd) FormatOutput(outputType string) KCmd
- func (k KCmd) InNamespace(namespace string) KCmd
- func (k KCmd) Output() (string, error)
- func (k KCmd) OutputPanic() string
- func (k KCmd) ToCliArgs() []string
- func (k KCmd) WithFlag(name string, value string) KCmd
- func (k KCmd) WithLabel(label string) KCmd
Constants ¶
const ( // Credentials for creating an ImagePullSecret EnvDockerUsername = "M_DOCKER_USERNAME" EnvDockerPassword = "M_DOCKER_PASSWORD" EnvDockerServer = "M_DOCKER_SERVER" )
Variables ¶
This section is empty.
Functions ¶
func DockerCredentialsDefined ¶
func DockerCredentialsDefined() bool
func DumpClusterInfo ¶ added in v1.10.3
DumpClusterInfo Executes `kubectl cluster-info dump -o yaml` on each cluster. The output is stored under <project-root>/build/test.
func GetKubeconfig ¶
func WatchPodsInNs ¶
func WatchPodsInNs(namespace string)
Types ¶
type KCmd ¶
============================================== KCmd represents an executable kubectl command ==============================================
func ApplyFiles ¶
func ClusterInfoForContext ¶
func CreateFromFiles ¶
func CreateNamespace ¶
func DeleteByTypeAndName ¶
func DeleteFromFiles ¶
func DeleteNamespace ¶
func DumpAllLogs ¶
func GetByFiles ¶
func GetByTypeAndName ¶
func GetNodeNameForPod ¶
func PatchMerge ¶
func (KCmd) ExecV ¶
ExecV runs KCmd via `kubectl`, where KCmd is a struct holding the kubectl command to run (not including `kubectl` itself), the args, and any flags. Returns error only (no capture of results) and also logs logs output.
func (KCmd) ExecVCapture ¶
ExecV runs KCmd via `kubectl`, where KCmd is a struct holding the kubectl command to run (not including `kubectl` itself), the args, and any flags. Returns (stdout, stderr, error) and also logs logs output.
func (KCmd) ExecVPanic ¶
func (k KCmd) ExecVPanic()
func (KCmd) FormatOutput ¶
func (KCmd) InNamespace ¶
============================================== Helper functions to build up a KCmd object for common actions ==============================================