Documentation ¶
Index ¶
- Constants
- type BuilderOptions
- type Client
- func (c *Client) Apply(content []byte) error
- func (c *Client) ApplyFiles(filenames ...string) error
- func (c *Client) ApplyResource(r *resource.Result) error
- func (c *Client) Create(content []byte) error
- func (c *Client) CreateFile(filenames ...string) error
- func (c *Client) CreateNamespace(namespace string) error
- func (c *Client) CreateResource(r *resource.Result) error
- func (c *Client) Delete(content []byte) error
- func (c *Client) DeleteFiles(filenames ...string) error
- func (c *Client) DeleteNamespace(namespace string) error
- func (c *Client) DeleteResource(r *resource.Result) error
- func (c *Client) NodesReady() (ready int, total int, err error)
- func (c *Client) Replace(content []byte) error
- func (c *Client) ReplaceFiles(filenames ...string) error
- func (c *Client) ReplaceResource(r *resource.Result) error
- func (c *Client) ResultForContent(content []byte, opt *BuilderOptions) *Result
- func (c *Client) ResultForFilenameParam(filenames []string, opt *BuilderOptions) *Result
- func (c *Client) ResultForReader(r io.Reader, opt *BuilderOptions) *Result
- func (c *Client) Version() (string, error)
- type Result
Constants ¶
const DefaultValidation = true
DefaultValidation default action to validate. If `true` all resources by default will be validated.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuilderOptions ¶
type BuilderOptions struct { Unstructured bool Validate bool Namespace string LabelSelector string FieldSelector string All bool AllNamespaces bool }
BuilderOptions parameters to create a Resource Builder
func NewBuilderOptions ¶
func NewBuilderOptions() *BuilderOptions
NewBuilderOptions creates a BuilderOptions with the default values for the parameters to create a Resource Builder
type Client ¶
type Client struct { Clientset *kubernetes.Clientset ServerSideApply bool // contains filtered or unexported fields }
Client is a kubernetes client, like `kubectl`
func (*Client) ApplyFiles ¶
ApplyFiles create the resource(s) from the given filenames (file, directory or STDIN) or HTTP URLs
func (*Client) ApplyResource ¶
ApplyResource applies the given resource. Create the resources with `ResultForFilenameParam` or `ResultForContent`
func (*Client) CreateFile ¶
CreateFile creates a resource with the given content
func (*Client) CreateNamespace ¶
CreateNamespace creates a namespace with the given name
func (*Client) CreateResource ¶
CreateResource creates the given resource. Create the resources with `ResultForFilenameParam` or `ResultForContent`
func (*Client) DeleteFiles ¶
DeleteFiles create the resource(s) from the given filenames (file, directory or STDIN) or HTTP URLs
func (*Client) DeleteNamespace ¶
DeleteNamespace deletes the namespace with the given name
func (*Client) DeleteResource ¶
DeleteResource applies the given resource. Create the resources with `ResultForFilenameParam` or `ResultForContent`
func (*Client) NodesReady ¶
NodesReady returns the number of nodes ready
func (*Client) ReplaceFiles ¶
ReplaceFiles create the resource(s) from the given filenames (file, directory or STDIN) or HTTP URLs
func (*Client) ReplaceResource ¶
ReplaceResource applies the given resource. Create the resources with `ResultForFilenameParam` or `ResultForContent`
func (*Client) ResultForContent ¶
func (c *Client) ResultForContent(content []byte, opt *BuilderOptions) *Result
ResultForContent returns the builder results for the given content
func (*Client) ResultForFilenameParam ¶
func (c *Client) ResultForFilenameParam(filenames []string, opt *BuilderOptions) *Result
ResultForFilenameParam returns the builder results for the given list of files or URLs
func (*Client) ResultForReader ¶
func (c *Client) ResultForReader(r io.Reader, opt *BuilderOptions) *Result
ResultForReader returns the builder results for the given reader