spotprice

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2023 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StackName string = "Spot-Price"

	StackOutputRegion           string = "Region"
	StackOutputAvailabilityZone string = "AvailabilityZone"
	StackOutputAVGPrice         string = "AVGPrice"
	StackOutputMaxPrice         string = "MaxPrice"
	StackOutputScore            string = "Score"
)

Variables

This section is empty.

Functions

func Destroy

func Destroy(projectName, backedURL string) (err error)

func GetBestPlacementScores

func GetBestPlacementScores(regions, instanceTypes []string,
	capacity int64) ([]*awsEC2.SpotPlacementScore, error)

return sps ordered from max to min by score

Types

type BestSpotBid

type BestSpotBid struct {
	pulumi.ResourceState
	Price *SpotPriceGroup
}

func BestSpotBidOrder

func BestSpotBidOrder(ctx *pulumi.Context, name string, targetHostID string, opts ...pulumi.ResourceOption) (*BestSpotBid, error)

type SpotPriceGroup

type SpotPriceGroup struct {
	Region           string
	AvailabilityZone string
	AVGPrice         float64
	MaxPrice         float64
	Score            int64
}

func BestSpotPriceInfo

func BestSpotPriceInfo(targetHostID string) (*SpotPriceGroup, error)

func Create

func Create(projectName, backedURL, targetHostID string) (*SpotPriceGroup, error)

type SpotPriceRequest

type SpotPriceRequest struct {
	TargetHostID string
	Name         string
}

type SpotPriceResult

type SpotPriceResult struct {
	Prices []SpotPriceGroup
	Err    error
}

Jump to

Keyboard shortcuts

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