KubectlAttachSettings Class

Summary

Attach to a process that is already running inside an existing container.
Assembly
Cake.Kubectl.dll
Namespace
Cake.Kubectl
Base Types
graph BT Type-->Base0["AutoToolSettings"] click Base0 "/api/Cake.Kubectl/AutoToolSettings" Base0-->Base1["ToolSettings"] Type["KubectlAttachSettings"] class Type type-node

Syntax

public sealed class KubectlAttachSettings : AutoToolSettings

Examples

# Get output from running pod mypod; use the 'kubectl.kubernetes.io/default-container' annotation # for selecting the container to be attached or the first container in the pod will be chosen kubectl attach mypod # Get output from ruby-container from pod mypod kubectl attach mypod -c ruby-container # Switch to raw terminal mode; sends stdin to 'bash' in ruby-container from pod mypod # and sends stdout/stderr from 'bash' back to the client kubectl attach mypod -c ruby-container -i -t # Get output from the first pod of a replica set named nginx kubectl attach rs/nginx

Attributes

Type Description
NullableContextAttribute
NullableAttribute
CompilerGeneratedAttribute

Constructors

Properties

Name Value Summary
Container string
-c, --container Container name. If omitted, use the kubectl.kubernetes.io/default-container annotation for selecting the container to be attached or the first container in the pod will be chosen
PodRunningTimeout string
--pod-running-timeout The length of time (like 5s, 2m, or 3h, higher than zero) to wait until at least one pod is running
Quiet Nullable<bool>
-q, --quiet Only print output from the remote session
Stdin Nullable<bool>
-i, --stdin Pass stdin to the container
Tty Nullable<bool>
-t, --tty Stdin is a TTY

Extension Methods

Name Value Summary
Dump<KubectlAttachSettings>() string
Get a basic string representation of specified object.
Requires the Cake.Incubator addin
IsIn<KubectlAttachSettings>(KubectlAttachSettings[]) bool
Checks if the source is contained in a list
Requires the Cake.Incubator addin
NotNull<KubectlAttachSettings>(string) void
Throws an exception if the specified parameter's value is null.
Requires the Cake.Ftp addin
NotNull<KubectlAttachSettings>(string) void
Throws an exception if the specified parameter's value is null.
Requires the Cake.Issues addin
ThrowIfNull<KubectlAttachSettings>(string, string) T
Throws a System.ArgumentNullException with a specific message if the value is null, otherwise returns the value
Requires the Cake.Incubator addin
ThrowIfNull<KubectlAttachSettings>(string) T
Throws a System.ArgumentNullException if the value is null, otherwise returns the value
Requires the Cake.Incubator addin
ToDictionary() IDictionary<string, object>
Requires the Cake.DeployParams addin
ToStringWithNullMarkup() string
Returns the string value or a Not set> markup suitable for Spectre.Console.
Requires the Cake.Issues addin