Versions in this module Expand all Collapse all v0 v0.17.0 Apr 30, 2024 v0.16.0 Nov 9, 2023 Changes in this version + func InstanceIPs(inst *compute.Instance) (intIP, extIP string) + func ParseDisk(spec string, zone string) (*compute.AttachedDisk, error) + type API struct + func New(opts *Options) (*API, error) + func (a *API) Client() *http.Client + func (a *API) CreateImage(spec *ImageSpec, overwrite bool) (*compute.Operation, *Pending, error) + func (a *API) CreateInstance(userdata string, keys []*agent.Key, opts platform.MachineOptions, ...) (*compute.Instance, error) + func (a *API) DeleteImage(name string) (*Pending, error) + func (a *API) DeprecateImage(name string, state DeprecationState, replacement string) (*Pending, error) + func (a *API) GC(gracePeriod time.Duration) error + func (a *API) GetConsoleOutput(name string) (string, error) + func (a *API) GetPendingForImage(image *compute.Image) (*Pending, error) + func (a *API) ListImages(ctx context.Context, prefix string, family string) ([]*compute.Image, error) + func (a *API) ListInstances(prefix string) ([]*compute.Instance, error) + func (a *API) NewPending(desc string, do doable) *Pending + func (a *API) SetImagePublic(name string) error + func (a *API) TerminateInstance(name string) error + func (a *API) UpdateImage(name string, family string, description string) (*Pending, error) + type DeprecationState string + const DeprecationStateActive + const DeprecationStateDeleted + const DeprecationStateDeprecated + const DeprecationStateObsolete + type ImageSpec struct + Architecture string + Description string + Family string + Licenses []string + Name string + SourceImage string + type Options struct + Confidential bool + DiskType string + Image string + JSONKeyFile string + MachineType string + Network string + Project string + ServiceAcct string + ServiceAuth bool + Zone string + type Pending struct + Interval time.Duration + Progress func(desc string, elapsed time.Duration, op *compute.Operation) error + Timeout time.Duration + func (p *Pending) Wait() error