resources

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GenericResource

type GenericResource struct {
	Address           string
	Name              string
	Region            string
	Provider          providers.Provider
	GPUTypes          []string
	CPUTypes          []string
	VCPUs             int32
	MemoryMb          int32
	Storage           Storage
	ReplicationFactor int32
}

GenericResource is a struct that contains the information of a generic resource

func GetResource

func GetResource(instanceType string, zone string, provider providers.Provider) (GenericResource, error)

GetResource returns a GenericResource from an instance type

func (GenericResource) GetAddress

func (g GenericResource) GetAddress() string

GetAddress returns the address of the resource

func (GenericResource) GetIdentification

func (g GenericResource) GetIdentification() *resources.ResourceIdentification

GetIdentification returns the identification of the resource

func (GenericResource) IsSupported

func (g GenericResource) IsSupported() bool

IsSupported returns true if the resource is supported by carbonifer. At the moment, only GCP is supported.

type Storage

type Storage struct {
	HddStorage decimal.Decimal
	SsdStorage decimal.Decimal
}

Storage is the struct that contains the storage of a resource

Jump to

Keyboard shortcuts

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