Documentation ¶
Index ¶
- func Create[T Resource](apiClient kubernetes.Interface, namespace string, spec T, ...) (T, error)
- func DecodeInto[T Resource](data []byte, into T) error
- func DecodeIntoString[T Resource](input string, into T) error
- func Delete[T Resource](apiClient kubernetes.Interface, namespace, name string, ...) error
- func Get[T Resource](apiClient kubernetes.Interface, namespace, name string, opt metav1.GetOptions) (T, error)
- func List[T Resource](apiClient kubernetes.Interface, namespace string, opt metav1.ListOptions) ([]T, error)
- func PrintJSON[T Resource](obj T, w io.Writer) error
- func PrintYAML[T Resource](obj T, w io.Writer) error
- type Config
- type Resource
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Create ¶
func Create[T Resource](apiClient kubernetes.Interface, namespace string, spec T, opt metav1.CreateOptions) (T, error)
func DecodeInto ¶
func DecodeIntoString ¶
func Delete ¶
func Delete[T Resource](apiClient kubernetes.Interface, namespace, name string, opt metav1.DeleteOptions) error
func Get ¶
func Get[T Resource](apiClient kubernetes.Interface, namespace, name string, opt metav1.GetOptions) (T, error)
func List ¶
func List[T Resource](apiClient kubernetes.Interface, namespace string, opt metav1.ListOptions) ([]T, error)
Types ¶
type Config ¶
type Config struct { RestConfig *rest.Config APIClient kubernetes.Interface }
func FromKubeConfig ¶
FromKubeConfig - Init K8s Client with kubeconfig file $USER/.kube/config
func FromKubeConfigPath ¶
FromKubeConfigPath - Init K8s Client with specific kubeconfig file
func FromRestConfig ¶
FromRestConfig - Init K8s Client with rest configuration
Click to show internal directories.
Click to hide internal directories.