Class SpotDatafeedSubscription
Note: There is only a single subscription allowed per account.
To help you understand the charges for your Spot instances, Amazon EC2 provides a data feed that describes your Spot instance usage and pricing. This data feed is sent to an Amazon S3 bucket that you specify when you subscribe to the data feed.
Example Usage
using Pulumi;
using Aws = Pulumi.Aws;
class MyStack : Stack
{
public MyStack()
{
var defaultBucket = new Aws.S3.Bucket("defaultBucket", new Aws.S3.BucketArgs
{
});
var defaultSpotDatafeedSubscription = new Aws.Ec2.SpotDatafeedSubscription("defaultSpotDatafeedSubscription", new Aws.Ec2.SpotDatafeedSubscriptionArgs
{
Bucket = defaultBucket.BucketName,
Prefix = "my_subdirectory",
});
}
}
Inherited Members
Namespace: Pulumi.Aws.Ec2
Assembly: Pulumi.Aws.dll
Syntax
public class SpotDatafeedSubscription : CustomResource
Constructors
View SourceSpotDatafeedSubscription(String, SpotDatafeedSubscriptionArgs, CustomResourceOptions)
Create a SpotDatafeedSubscription resource with the given unique name, arguments, and options.
Declaration
public SpotDatafeedSubscription(string name, SpotDatafeedSubscriptionArgs args, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resource |
| SpotDatafeedSubscriptionArgs | args | The arguments used to populate this resource's properties |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Properties
View SourceBucket
The Amazon S3 bucket in which to store the Spot instance data feed.
Declaration
public Output<string> Bucket { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Prefix
Path of folder inside bucket to place spot pricing data.
Declaration
public Output<string> Prefix { get; }
Property Value
| Type | Description |
|---|---|
| Output<System.String> |
Methods
View SourceGet(String, Input<String>, SpotDatafeedSubscriptionState, CustomResourceOptions)
Get an existing SpotDatafeedSubscription resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
Declaration
public static SpotDatafeedSubscription Get(string name, Input<string> id, SpotDatafeedSubscriptionState state = null, CustomResourceOptions options = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | name | The unique name of the resulting resource. |
| Input<System.String> | id | The unique provider ID of the resource to lookup. |
| SpotDatafeedSubscriptionState | state | Any extra arguments used during the lookup. |
| CustomResourceOptions | options | A bag of options that control this resource's behavior |
Returns
| Type | Description |
|---|---|
| SpotDatafeedSubscription |