Documentation ¶
Index ¶
- Variables
- type Block
- type Client
- func NewClient(address, user, password string) (Client, error)
- func NewClientThroughTsuru(target, token, service string) (Client, error)
- func NewClientThroughTsuruWithOptions(target, token, service string, opts ClientOptions) (Client, error)
- func NewClientWithOptions(address, user, password string, opts ClientOptions) (Client, error)
- type ClientOptions
- type DeleteBlockArgs
- type DeleteRouteArgs
- type ListBlocksArgs
- type ListRoutesArgs
- type Route
- type ScaleArgs
- type UpdateBlockArgs
- type UpdateCertificateArgs
- type UpdateRouteArgs
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrMissingTsuruTarget = fmt.Errorf("rpaasv2: tsuru target cannot be empty") ErrMissingTsuruToken = fmt.Errorf("rpaasv2: tsuru token cannot be empty") ErrMissingTsuruService = fmt.Errorf("rpaasv2: tsuru service cannot be empty") ErrMissingInstance = fmt.Errorf("rpaasv2: instance cannot be empty") ErrMissingBlockName = fmt.Errorf("rpaasv2: block name cannot be empty") ErrMissingPath = fmt.Errorf("rpaasv2: path cannot be empty") ErrUnexpectedStatusCode = fmt.Errorf("rpaasv2: unexpected status code") )
View Source
var DefaultClientOptions = ClientOptions{ Timeout: 10 * time.Second, }
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client interface { GetPlans(ctx context.Context, instance string) ([]types.Plan, *http.Response, error) GetFlavors(ctx context.Context, instance string) ([]types.Flavor, *http.Response, error) Scale(ctx context.Context, args ScaleArgs) (*http.Response, error) UpdateCertificate(ctx context.Context, args UpdateCertificateArgs) (*http.Response, error) UpdateBlock(ctx context.Context, args UpdateBlockArgs) (*http.Response, error) DeleteBlock(ctx context.Context, args DeleteBlockArgs) (*http.Response, error) ListBlocks(ctx context.Context, args ListBlocksArgs) ([]Block, *http.Response, error) DeleteRoute(ctx context.Context, args DeleteRouteArgs) (*http.Response, error) ListRoutes(ctx context.Context, args ListRoutesArgs) ([]Route, *http.Response, error) UpdateRoute(ctx context.Context, args UpdateRouteArgs) (*http.Response, error) }
func NewClientThroughTsuru ¶
func NewClientThroughTsuruWithOptions ¶
func NewClientThroughTsuruWithOptions(target, token, service string, opts ClientOptions) (Client, error)
func NewClientWithOptions ¶
func NewClientWithOptions(address, user, password string, opts ClientOptions) (Client, error)
type ClientOptions ¶
type DeleteBlockArgs ¶
func (DeleteBlockArgs) Validate ¶
func (args DeleteBlockArgs) Validate() error
type DeleteRouteArgs ¶
func (DeleteRouteArgs) Validate ¶
func (args DeleteRouteArgs) Validate() error
type ListBlocksArgs ¶
type ListBlocksArgs struct {
Instance string
}
func (ListBlocksArgs) Validate ¶
func (args ListBlocksArgs) Validate() error
type ListRoutesArgs ¶
type ListRoutesArgs struct {
Instance string
}
func (ListRoutesArgs) Validate ¶
func (args ListRoutesArgs) Validate() error
type UpdateBlockArgs ¶
func (UpdateBlockArgs) Validate ¶
func (args UpdateBlockArgs) Validate() error
type UpdateCertificateArgs ¶
type UpdateCertificateArgs struct { Instance string Name string Certificate string Key string // contains filtered or unexported fields }
func (UpdateCertificateArgs) Validate ¶
func (args UpdateCertificateArgs) Validate() error
Click to show internal directories.
Click to hide internal directories.