Documentation ¶
Index ¶
- Variables
- func GetComputeResource(resourceI interface{}, resourceMapping *ResourceMapping, ...) ([]resources.Resource, error)
- func GetResources(tfplan *map[string]interface{}) (map[string]resources.Resource, error)
- type DiskType
- type DiskTypes
- type GeneralConfig
- type Mappings
- type PropertyDefinition
- type Reference
- type Regex
- type ResourceMapping
- type UnsupportedDiskTypeError
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidDiskType = errors.New("not a valid DiskType")
View Source
var TfPlan *map[string]interface{}
TfPlan is the Terraform plan
Functions ¶
func GetComputeResource ¶ added in v0.4.0
Types ¶
type DiskType ¶ added in v0.4.0
type DiskType int
ENUM(SSD, HDD)
func ParseDiskType ¶ added in v0.4.0
ParseDiskType attempts to convert a string to a DiskType.
func (DiskType) MarshalText ¶ added in v0.4.0
MarshalText implements the text marshaller method.
func (*DiskType) UnmarshalText ¶ added in v0.4.0
UnmarshalText implements the text unmarshaller method.
type GeneralConfig ¶ added in v0.4.0
type Mappings ¶ added in v0.4.0
type Mappings struct { General *map[providers.Provider]GeneralConfig `yaml:"general,omitempty"` ComputeResource *map[string]ResourceMapping `yaml:"compute_resource,omitempty"` }
func GetMapping ¶ added in v0.4.0
GetMapping returns the mapping of the terraform resources
type PropertyDefinition ¶ added in v0.4.0
type PropertyDefinition struct { Paths []string `yaml:"paths"` Unit *string `yaml:"unit,omitempty"` Default interface{} `yaml:"default,omitempty"` ValueType *string `yaml:"value_type,omitempty"` Reference *Reference `yaml:"reference,omitempty"` Regex *Regex `yaml:"regex,omitempty"` Item *[]ResourceMapping `yaml:"item,omitempty"` Validator *string `yaml:"validator,omitempty"` }
type ResourceMapping ¶ added in v0.4.0
type ResourceMapping struct { Paths []string `yaml:"paths"` Type string `yaml:"type"` Variables *ResourceMapping `yaml:"variables,omitempty"` Properties *map[string][]PropertyDefinition `yaml:"properties"` }
type UnsupportedDiskTypeError ¶ added in v0.4.0
type UnsupportedDiskTypeError struct {
DiskType string
}
UnsupportedDiskTypeError is an error that occurs when a disk type is not supported
func (*UnsupportedDiskTypeError) Error ¶ added in v0.4.0
func (upe *UnsupportedDiskTypeError) Error() string
Click to show internal directories.
Click to hide internal directories.