Documentation
¶
Index ¶
- type Client
- func (r *Client) AddCertificate(name, descr string, privateKey, cert []byte) (*rancherClient.Certificate, error)
- func (r *Client) FindCertByName(name string) (*rancherClient.Certificate, error)
- func (r *Client) GetCertById(certId string) (*rancherClient.Certificate, error)
- func (r *Client) UpdateCertificate(certId, descr string, privateKey, cert []byte) error
- func (r *Client) UpdateLoadBalancers(certId string) error
- func (r *Client) WaitCertificate(certificate *rancherClient.Certificate) error
- func (r *Client) WaitFor(resource *rancherClient.Resource, output interface{}, ...) error
- func (r *Client) WaitLoadBalancerService(lb *rancherClient.LoadBalancerService) error
- func (r *Client) WaitService(service *rancherClient.Service) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(rancherUrl string, rancherAccessKey string, rancherSecretKey string) (*Client, error)
NewClient returns a new client for the Rancher/Cattle API
func (*Client) AddCertificate ¶
func (r *Client) AddCertificate(name, descr string, privateKey, cert []byte) (*rancherClient.Certificate, error)
AddCertificate creates a new certificate resource using the given private key and PEM encoded certificate
func (*Client) FindCertByName ¶
func (r *Client) FindCertByName(name string) (*rancherClient.Certificate, error)
FindCertByName retrieves an existing certificate
func (*Client) GetCertById ¶
func (r *Client) GetCertById(certId string) (*rancherClient.Certificate, error)
GetCertById retrieves an existing certificate by ID
func (*Client) UpdateCertificate ¶
UpdateCertificate updates an existing certificate resource using the given PEM encoded certificate
func (*Client) UpdateLoadBalancers ¶ added in v0.4.0
UpdateLoadBalancers updates all load balancers with the renewed certificate
func (*Client) WaitCertificate ¶
func (r *Client) WaitCertificate(certificate *rancherClient.Certificate) error
WaitCertificate waits for a certificate resource to transition
func (*Client) WaitFor ¶
func (r *Client) WaitFor(resource *rancherClient.Resource, output interface{}, transitioning func() string) error
WaitFor waits for a resource to reach a certain state.
func (*Client) WaitLoadBalancerService ¶
func (r *Client) WaitLoadBalancerService(lb *rancherClient.LoadBalancerService) error
WaitLoadBalancerService waits for a loadbalancer service resource to transition
func (*Client) WaitService ¶
func (r *Client) WaitService(service *rancherClient.Service) error
WaitService waits for a loadbalancer resource to transition