Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DigitalOcean ¶
type DigitalOcean struct {
// contains filtered or unexported fields
}
DigitalOcean is an implementation of CloudProvider for DigitalOcean
func NewDigitalOcean ¶
func NewDigitalOcean() (*DigitalOcean, error)
NewDigitalOcean instantiates a new DigitalOcean CloudProvider
func (DigitalOcean) CreateNode ¶
func (do DigitalOcean) CreateNode(ctx context.Context, node model.Node, callback func(string, string), onError func(error))
CreateNode creates a volume and a droplet and installs geth.
func (DigitalOcean) DeleteNode ¶
func (do DigitalOcean) DeleteNode(ctx context.Context, node model.Node, onSuccess func(), onError func(error))
DeleteNode deletes the droplet and the attached volume and firewall. The firewall is deleted first, because the droplet needs to exists when looking for the firewall. The volume is deleted last, because we can't delete a volume attached to an existing droplet.
type TokenSource ¶
type TokenSource struct {
AccessToken string
}
TokenSource stores the OAuth2 access token string
Click to show internal directories.
Click to hide internal directories.