hcloud

package
v0.3.2 Latest Latest
Warning

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

Go to latest
Published: Aug 3, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ActionStatusError   = hcloud.ActionStatusError
	ActionStatusSuccess = hcloud.ActionStatusSuccess
	ActionStatusRunning = hcloud.ActionStatusRunning
)

ActionStatus

View Source
const (
	FloatingIPTypeIPv4 = hcloud.FloatingIPTypeIPv4
	FloatingIPTypeIPv6 = hcloud.FloatingIPTypeIPv6
)

Floating IP types.

Variables

View Source
var (
	ServerStatusOff     = hcloud.ServerStatusOff
	ServerStatusRunning = hcloud.ServerStatusRunning
)

ServerStatus alias of hcloud.ServerStatus*

Functions

func Bool added in v0.3.2

func Bool(b bool) *bool

Bool alias of hcloud.Bool

func String

func String(s string) *string

String alias of hcloud.String

Types

type Action

type Action = hcloud.Action

Action alias of hcloud.Action

type ActionClient

type ActionClient interface {
	GetByID(ctx context.Context, id int) (*hcloud.Action, *hcloud.Response, error)
	List(ctx context.Context, opts hcloud.ActionListOpts) ([]*hcloud.Action, *hcloud.Response, error)
	All(ctx context.Context) ([]*hcloud.Action, error)
	WatchProgress(ctx context.Context, action *hcloud.Action) (<-chan int, <-chan error)
}

ActionClient interface of hcloud.ActionClient

type ActionStatus

type ActionStatus = hcloud.ActionStatus

ActionStatus alias of hcloud.ActionStatus

type Client

type Client struct {
	*hcloud.Client
	Action     ActionClient
	Datacenter DatacenterClient
	FloatingIP FloatingIPClient
	Image      ImageClient
	ISO        ISOClient
	Location   LocationClient
	Pricing    PricingClient
	Server     ServerClient
	ServerType ServerTypeClient
	SSHKey     SSHKeyClient
}

Client is an alias using interfaces of hcloud.Client

func BuildClient

func BuildClient(token string) (*Client, error)

BuildClient creates and configures an hcloud client

func NewClient

func NewClient(options ...hcloud.ClientOption) *Client

NewClient is creates a new wrapped client

type ClientOption

type ClientOption = hcloud.ClientOption

ClientOption alias of hcloud.ClientOption

func WithEndpoint

func WithEndpoint(token string) ClientOption

WithEndpoint alias of hcloud.WithEndpoint

func WithToken

func WithToken(token string) ClientOption

WithToken alias of hcloud.WithToken

type Datacenter

type Datacenter = hcloud.Datacenter

Datacenter alias of hcloud.Datacenter

type DatacenterClient

type DatacenterClient interface {
	GetByID(ctx context.Context, id int) (*hcloud.Datacenter, *hcloud.Response, error)
	GetByName(ctx context.Context, name string) (*hcloud.Datacenter, *hcloud.Response, error)
	Get(ctx context.Context, idOrName string) (*hcloud.Datacenter, *hcloud.Response, error)
	List(ctx context.Context, opts hcloud.DatacenterListOpts) ([]*hcloud.Datacenter, *hcloud.Response, error)
	All(ctx context.Context) ([]*hcloud.Datacenter, error)
}

DatacenterClient interface of hcloud.DatacenterClient

type FloatingIP

type FloatingIP = hcloud.FloatingIP

FloatingIP alias of hcloud.FloatingIP

type FloatingIPClient

type FloatingIPClient interface {
	GetByID(ctx context.Context, id int) (*FloatingIP, *Response, error)
	List(ctx context.Context, opts FloatingIPListOpts) ([]*FloatingIP, *Response, error)
	All(ctx context.Context) ([]*FloatingIP, error)
	Create(ctx context.Context, opts FloatingIPCreateOpts) (FloatingIPCreateResult, *Response, error)
	Delete(ctx context.Context, floatingIP *FloatingIP) (*Response, error)
	Assign(ctx context.Context, floatingIP *FloatingIP, server *Server) (*Action, *Response, error)
	Unassign(ctx context.Context, floatingIP *FloatingIP) (*Action, *Response, error)
	Update(ctx context.Context, floatingIP *FloatingIP, opts FloatingIPUpdateOpts) (*FloatingIP, *Response, error)
}

FloatingIPClient interface of hcloud.FloatingIPClient

type FloatingIPCreateOpts

type FloatingIPCreateOpts = hcloud.FloatingIPCreateOpts

FloatingIPCreateOpts alias of hcloud.FloatingIPCreateOpts

type FloatingIPCreateResult

type FloatingIPCreateResult = hcloud.FloatingIPCreateResult

FloatingIPCreateResult alias of hcloud.FloatingIPCreateResult

type FloatingIPListOpts

type FloatingIPListOpts = hcloud.FloatingIPListOpts

FloatingIPListOpts alias of hcloud.FloatingIPListOpts

type FloatingIPType

type FloatingIPType = hcloud.FloatingIPType

FloatingIPType alias of hcloud.FloatingIPType

type FloatingIPUpdateOpts

type FloatingIPUpdateOpts = hcloud.FloatingIPUpdateOpts

FloatingIPUpdateOpts alias of hcloud.FloatingIPUpdateOpts

type ISO added in v0.3.2

type ISO = hcloud.ISO

ISO alias of hcloud.ISO

type ISOClient

type ISOClient interface {
	GetByID(ctx context.Context, id int) (*hcloud.ISO, *hcloud.Response, error)
	GetByName(ctx context.Context, name string) (*hcloud.ISO, *hcloud.Response, error)
	Get(ctx context.Context, idOrName string) (*hcloud.ISO, *hcloud.Response, error)
}

ISOClient interface of hcloud.ISOClient

type Image

type Image = hcloud.Image

Image alias of hcloud.Image

type ImageClient

type ImageClient interface {
	GetByID(ctx context.Context, id int) (*hcloud.Image, *hcloud.Response, error)
	GetByName(ctx context.Context, name string) (*hcloud.Image, *hcloud.Response, error)
	Get(ctx context.Context, idOrName string) (*hcloud.Image, *hcloud.Response, error)
	List(ctx context.Context, opts hcloud.ImageListOpts) ([]*hcloud.Image, *hcloud.Response, error)
	All(ctx context.Context) ([]*hcloud.Image, error)
}

ImageClient interface of hcloud.ImageClient

type ImageListOpts added in v0.3.0

type ImageListOpts = hcloud.ImageListOpts

ImageListOpts alias of hcloud.ImageListOpts

type Location

type Location = hcloud.Location

Location alias of hcloud.Location

type LocationClient

type LocationClient interface {
	Get(ctx context.Context, idOrName string) (*hcloud.Location, *hcloud.Response, error)
}

LocationClient interface of hcloud.LocationClient

type PricingClient

type PricingClient interface{}

PricingClient interface of hcloud.PricingClient

type Response

type Response = hcloud.Response

Response alias of hcloud.Response

type SSHKey

type SSHKey = hcloud.SSHKey

SSHKey alias of hcloud.SSHKey

type SSHKeyClient

type SSHKeyClient interface {
	GetByID(ctx context.Context, id int) (*SSHKey, *Response, error)
	GetByName(ctx context.Context, name string) (*SSHKey, *Response, error)
	Get(ctx context.Context, idOrName string) (*SSHKey, *Response, error)
	All(ctx context.Context) ([]*SSHKey, error)
	Create(ctx context.Context, opts SSHKeyCreateOpts) (*SSHKey, *Response, error)
	Delete(ctx context.Context, sshKey *SSHKey) (*Response, error)
	Update(ctx context.Context, sshKey *SSHKey, opts SSHKeyUpdateOpts) (*SSHKey, *Response, error)
}

SSHKeyClient interface of hcloud.SSHKeyClient

type SSHKeyCreateOpts

type SSHKeyCreateOpts = hcloud.SSHKeyCreateOpts

SSHKeyCreateOpts alias of hcloud.SSHKeyCreateOpts

type SSHKeyUpdateOpts

type SSHKeyUpdateOpts = hcloud.SSHKeyUpdateOpts

SSHKeyUpdateOpts alias of hcloud.SSHKeyUpdateOpts

type Server

type Server = hcloud.Server

Server alias of hcloud.Server

type ServerClient

type ServerClient interface {
	GetByID(ctx context.Context, id int) (*Server, *Response, error)
	GetByName(ctx context.Context, name string) (*Server, *Response, error)
	Get(ctx context.Context, idOrName string) (*Server, *Response, error)
	// List(ctx context.Context, opts ServerListOpts) ([]*Server, *Response, error)
	All(ctx context.Context) ([]*Server, error)
	Create(ctx context.Context, opts ServerCreateOpts) (ServerCreateResult, *Response, error)
	Delete(ctx context.Context, server *Server) (*Response, error)
	Update(ctx context.Context, server *Server, opts ServerUpdateOpts) (*Server, *Response, error)
	Poweron(ctx context.Context, server *Server) (*Action, *Response, error)
	Reboot(ctx context.Context, server *Server) (*Action, *Response, error)
	Reset(ctx context.Context, server *Server) (*Action, *Response, error)
	// Shutdown(ctx context.Context, server *Server) (*Action, *Response, error)
	Poweroff(ctx context.Context, server *Server) (*Action, *Response, error)
	// ResetPassword(ctx context.Context, server *Server) (ServerResetPasswordResult, *Response, error)
	// CreateImage(ctx context.Context, server *Server, opts *ServerCreateImageOpts) (ServerCreateImageResult, *Response, error)
	AttachISO(ctx context.Context, server *Server, iso *ISO) (*Action, *Response, error)
	DetachISO(ctx context.Context, server *Server) (*Action, *Response, error)
	EnableRescue(ctx context.Context, server *Server, opts ServerEnableRescueOpts) (ServerEnableRescueResult, *Response, error)
	DisableRescue(ctx context.Context, server *Server) (*Action, *Response, error)
	// Rebuild(ctx context.Context, server *Server, opts ServerRebuildOpts) (*Action, *Response, error)
	// AttachISO(ctx context.Context, server *Server, iso *ISO) (*Action, *Response, error)
	// DetachISO(ctx context.Context, server *Server) (*Action, *Response, error)
	EnableBackup(ctx context.Context, server *Server, window string) (*Action, *Response, error)
	DisableBackup(ctx context.Context, server *Server) (*Action, *Response, error)
}

ServerClient interface of hcloud.ServerClient

type ServerCreateOpts

type ServerCreateOpts = hcloud.ServerCreateOpts

ServerCreateOpts alias of hcloud.ServerCreateOpts

type ServerCreateResult added in v0.3.0

type ServerCreateResult = hcloud.ServerCreateResult

ServerCreateResult alias of hcloud.ServerCreateResult

type ServerEnableRescueOpts

type ServerEnableRescueOpts = hcloud.ServerEnableRescueOpts

ServerEnableRescueOpts alias of hcloud.ServerEnableRescueOpts

type ServerEnableRescueResult

type ServerEnableRescueResult = hcloud.ServerEnableRescueResult

ServerEnableRescueResult alias of hcloud.ServerEnableRescueResult

type ServerPublicNet added in v0.3.0

type ServerPublicNet = hcloud.ServerPublicNet

ServerPublicNet alias of hcloud.ServerPublicNet

type ServerPublicNetIPv4 added in v0.3.0

type ServerPublicNetIPv4 = hcloud.ServerPublicNetIPv4

ServerPublicNetIPv4 alias of hcloud.ServerPublicNetIPv4

type ServerPublicNetIPv6 added in v0.3.0

type ServerPublicNetIPv6 = hcloud.ServerPublicNetIPv6

ServerPublicNetIPv6 alias of hcloud.ServerPublicNetIPv6

type ServerRescueType

type ServerRescueType = hcloud.ServerRescueType

ServerRescueType alias of hcloud.ServerRescueType

type ServerStatus

type ServerStatus = hcloud.ServerStatus

ServerStatus alias of hcloud.ServerStatus

type ServerType

type ServerType = hcloud.ServerType

ServerType alias of hcloud.ServerType

type ServerTypeClient

type ServerTypeClient interface {
	Get(ctx context.Context, idOrName string) (*ServerType, *Response, error)
}

ServerTypeClient interface of hcloud.ServerTypeClient

type ServerTypeListOpts added in v0.3.0

type ServerTypeListOpts = hcloud.ServerTypeListOpts

ServerTypeListOpts alias of hcloud.ServerTypeListOpts

type ServerUpdateOpts

type ServerUpdateOpts = hcloud.ServerUpdateOpts

ServerUpdateOpts alias of hcloud.ServerUpdateOpts

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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