Documentation
¶
Index ¶
- func ClientConfigPath() string
- func SaveClientConfig(cfg *ClientConfig) error
- type AppInfo
- type Client
- func (c *Client) DeployApp(name string, composeData []byte) error
- func (c *Client) GetApp(slug string) (*AppInfo, error)
- func (c *Client) GetAppCompose(slug string) ([]byte, error)
- func (c *Client) ListApps() ([]AppInfo, error)
- func (c *Client) ListBackupRuns(slug string) ([]json.RawMessage, error)
- func (c *Client) RemoveApp(slug string) error
- func (c *Client) Restore(runID int64) error
- func (c *Client) TriggerBackup(slug string) error
- type ClientConfig
- type Context
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ClientConfigPath ¶
func ClientConfigPath() string
func SaveClientConfig ¶
func SaveClientConfig(cfg *ClientConfig) error
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (*Client) ListBackupRuns ¶
func (c *Client) ListBackupRuns(slug string) ([]json.RawMessage, error)
func (*Client) TriggerBackup ¶
type ClientConfig ¶
type ClientConfig struct {
Contexts map[string]Context `yaml:"contexts"`
CurrentContext string `yaml:"current_context"`
}
func LoadClientConfig ¶
func LoadClientConfig() (*ClientConfig, error)
func (*ClientConfig) AddContext ¶
func (cfg *ClientConfig) AddContext(name, url, apiKey string)
func (*ClientConfig) GetCurrentContext ¶
func (cfg *ClientConfig) GetCurrentContext() (*Context, error)
func (*ClientConfig) UseContext ¶
func (cfg *ClientConfig) UseContext(name string) error
Click to show internal directories.
Click to hide internal directories.