compute

package
v0.7.1 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2024 License: MPL-2.0 Imports: 53 Imported by: 0

Documentation

Overview

This set of code handles all functions required to configure networking on an vkcs_compute_instance resource.

This is a complicated task because it's not possible to obtain all information in a single API call. In fact, it even traverses multiple OpenStack services.

The end result, from the user's point of view, is a structured set of understandable network information within the instance resource.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComputeInstanceReadTags

func ComputeInstanceReadTags(d *schema.ResourceData, tags []string)

func ComputeInstanceTags

func ComputeInstanceTags(d *schema.ResourceData) []string

func ComputeInstanceUpdateTags

func ComputeInstanceUpdateTags(d *schema.ResourceData) []string

func ComputeInterfaceAttachParseID

func ComputeInterfaceAttachParseID(id string) (string, string, error)

func ComputeVolumeAttachParseID

func ComputeVolumeAttachParseID(id string) (string, string, error)

func DataSourceComputeAvailabilityZones

func DataSourceComputeAvailabilityZones() *schema.Resource

func DataSourceComputeFlavor

func DataSourceComputeFlavor() *schema.Resource

func DataSourceComputeInstance

func DataSourceComputeInstance() *schema.Resource

func DataSourceComputeKeypair

func DataSourceComputeKeypair() *schema.Resource

func DataSourceComputeQuotaset

func DataSourceComputeQuotaset() *schema.Resource

func ExpandComputeServerGroupPolicies

func ExpandComputeServerGroupPolicies(client *gophercloud.ServiceClient, raw []interface{}) []string

func ParseComputeFloatingIPAssociateID

func ParseComputeFloatingIPAssociateID(id string) (string, string, string, error)

func ResourceComputeFloatingIPAssociate

func ResourceComputeFloatingIPAssociate() *schema.Resource

func ResourceComputeInstance

func ResourceComputeInstance() *schema.Resource

func ResourceComputeInterfaceAttach

func ResourceComputeInterfaceAttach() *schema.Resource

func ResourceComputeKeypair

func ResourceComputeKeypair() *schema.Resource

func ResourceComputeServerGroup

func ResourceComputeServerGroup() *schema.Resource

func ResourceComputeVolumeAttach

func ResourceComputeVolumeAttach() *schema.Resource

func ResourceInstanceBlockDevicesV2

func ResourceInstanceBlockDevicesV2(_ *schema.ResourceData, bds []interface{}) ([]bootfromvolume.BlockDevice, error)

func ServerStateRefreshFunc

func ServerStateRefreshFunc(client *gophercloud.ServiceClient, instanceID string) retry.StateRefreshFunc

ServerStateRefreshFunc returns a retry.StateRefreshFunc that is used to watch an VKCS instance.

Types

type ComputeKeyPairV2CreateOpts

type ComputeKeyPairV2CreateOpts struct {
	keypairs.CreateOpts
	ValueSpecs map[string]string `json:"value_specs,omitempty"`
}

ComputeKeyPairV2CreateOpts is a custom KeyPair struct to include the ValueSpecs field.

func (ComputeKeyPairV2CreateOpts) ToKeyPairCreateMap

func (opts ComputeKeyPairV2CreateOpts) ToKeyPairCreateMap() (map[string]interface{}, error)

ToKeyPairCreateMap casts a CreateOpts struct to a map. It overrides keypairs.ToKeyPairCreateMap to add the ValueSpecs field.

type ComputeServerGroupCreateOpts

type ComputeServerGroupCreateOpts struct {
	servergroups.CreateOpts
	ValueSpecs map[string]string `json:"value_specs,omitempty"`
}

ServerGroupCreateOpts is a custom ServerGroup struct to include the ValueSpecs field.

func (ComputeServerGroupCreateOpts) ToServerGroupCreateMap

func (opts ComputeServerGroupCreateOpts) ToServerGroupCreateMap() (map[string]interface{}, error)

ToServerGroupCreateMap casts a CreateOpts struct to a map. It overrides routers.ToServerGroupCreateMap to add the ValueSpecs field.

type InstanceAddresses

type InstanceAddresses struct {
	NetworkName  string
	InstanceNICs []InstanceNIC
}

InstanceAddresses is a collection of InstanceNICs, grouped by the network name. An instance/server could have multiple NICs on the same network.

type InstanceNIC

type InstanceNIC struct {
	FixedIPv4 string
	MAC       string
}

InstanceNIC is a structured representation of a Gophercloud servers.Server virtual NIC.

type InstanceNetwork

type InstanceNetwork struct {
	UUID          string
	Name          string
	Port          string
	FixedIP       string
	AccessNetwork bool
}

InstanceNetwork represents a collection of network information that a Terraform instance needs to satisfy all network information requirements.

Jump to

Keyboard shortcuts

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