database

package
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 25, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ArgSize      = "size"
	ArgInstances = "instances"
	ArgType      = "type"
	ArgName      = "name"
	ArgLabels    = "labels"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	JWT    string
	Host   string
	Scheme string
}

func (*Client) CreateDatabase

func (c *Client) CreateDatabase(ctx context.Context, input *CreateDatabaseInput) (*models.CreateDatabaseResponse, error)

Create a new database cluster

func (*Client) CreateDeployment

Create a new deployment

func (*Client) CreateIngress

func (c *Client) CreateIngress(ctx context.Context, input *CreateIngressInput) (*models.CreateIngressResponse, error)

Create a new network ingress (exposes the service to the public)

func (*Client) DeleteDatabase

func (c *Client) DeleteDatabase(ctx context.Context, input *DeleteDatabaseInput) error

Create a new database cluster

func (*Client) DeleteIngress

func (c *Client) DeleteIngress(ctx context.Context, input *DeleteIngressInput) (*models.DeleteResponse, error)

Create a new network ingress (exposes the service to the public)

func (*Client) ListDatabases

func (c *Client) ListDatabases(ctx context.Context, input *ListDatabaseInput) (*resty.Response, error)

List database clusters available

type CreateDatabaseInput

type CreateDatabaseInput struct {
	Size      string            `json:"size"`
	Instances string            `json:"instances"`
	Type      string            `json:"type"`
	Name      string            `json:"name"`
	Labels    map[string]string `json:"labels,omitempty"`
}

func NewCreateDatabaseInputFromFlags

func NewCreateDatabaseInputFromFlags(flags *pflag.FlagSet) (*CreateDatabaseInput, error)

type CreateIngressInput

type CreateIngressInput struct {
	Name string `json:"name"`
}

type DeleteDatabaseInput

type DeleteDatabaseInput struct {
	Name string
}

func NewDeleteInputFromFlags

func NewDeleteInputFromFlags(flags *pflag.FlagSet) (*DeleteDatabaseInput, error)

type DeleteIngressInput

type DeleteIngressInput struct {
	Name string `json:"name"`
}

type ListDatabaseInput

type ListDatabaseInput struct {
	Labels map[string]string `json:"labels,omitempty"`
}

func NewListDatabaseInputFromFlags

func NewListDatabaseInputFromFlags(flags *pflag.FlagSet) (*ListDatabaseInput, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL