fluxcloud.main.cloud.aws package

Submodules

fluxcloud.main.cloud.aws.client module

class fluxcloud.main.cloud.aws.client.AmazonCloud(**kwargs)[source]

Bases: fluxcloud.main.cloud.base.CloudProvider

An Amazon cloud provider wrapper

instances()[source]

Use the API to retrieve (and return) instances within a set of regions.

We do a little extra work to add the region attribute to make it accessible for filtering.

load_instances(data)[source]

Load instance data from json.

load_prices(data)[source]

Load prices data from json instal class

name = 'aws'
prices()[source]

Use the API to retrieve and return prices to cache.

fluxcloud.main.cloud.aws.instance module

class fluxcloud.main.cloud.aws.instance.AmazonInstance(items)[source]

Bases: fluxcloud.main.cloud.base.Instance

attr_cpus()[source]

Number of cpus the instance has.

attr_description()[source]

Put together a description that looks like Google’s

“208 vCPUs, 5.75 TB RAM”

attr_free_tier()[source]

Determine if an instance is free tier.

attr_gpu()[source]

Determine if an instance can support gpu

attr_gpus()[source]

Determine number of gpus an instance can support.

attr_ipv6()[source]

Determine if an instance can support ipv6

attr_memory()[source]

Memory is in GB

attr_price()[source]

Price of an instance, USD per hour.

This will only be populated - a single “Price” if prices are enabled and present for the region.

attr_region()[source]

Return the single region

property name
class fluxcloud.main.cloud.aws.instance.AmazonInstanceGroup(items)[source]

Bases: fluxcloud.main.cloud.base.InstanceGroup

A Google Cloud instance group.

An instance group stores raw data, and allows for query or other interaction over instances.

Instance

alias of fluxcloud.main.cloud.aws.instance.AmazonInstance

add_instance_prices(prices)[source]

Add pricing information to instances

We currently are filtering to Linux, OnDemand, and USD per hour. https://boto3.amazonaws.com/v1/documentation/api/latest/reference/services/pricing.html

filter_region(region)[source]

A request to filter down to a specific region regular expression.

The solver cannot handle this.

iter_instances()[source]

Amazon provides regions together, so here we yield instance data with just one region.

name_attribute = 'InstanceType'

fluxcloud.main.cloud.aws.prices module

class fluxcloud.main.cloud.aws.prices.AmazonPrices(items)[source]

Bases: fluxcloud.main.cloud.base.Prices

Google Compute Engine prices

Module contents