Use DescribeBundleTasks with a CLI - Amazon Elastic Compute Cloud
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Use DescribeBundleTasks with a CLI

The following code examples show how to use DescribeBundleTasks.

CLI
Amazon CLI

To describe your bundle tasks

This example describes all of your bundle tasks.

Command:

aws ec2 describe-bundle-tasks

Output:

{ "BundleTasks": [ { "UpdateTime": "2015-09-15T13:26:54.000Z", "InstanceId": "i-1234567890abcdef0", "Storage": { "S3": { "Prefix": "winami", "Bucket": "bundletasks" } }, "State": "bundling", "StartTime": "2015-09-15T13:24:35.000Z", "Progress": "3%", "BundleId": "bun-2a4e041c" } ] }
PowerShell
Tools for PowerShell

Example 1: This example describes the specified bundle task.

Get-EC2BundleTask -BundleId bun-12345678

Example 2: This example describes the bundle tasks whose state is either 'complete' or 'failed'.

$filter = New-Object Amazon.EC2.Model.Filter $filter.Name = "state" $filter.Values = @( "complete", "failed" ) Get-EC2BundleTask -Filter $filter

For a complete list of Amazon SDK developer guides and code examples, see Create Amazon EC2 resources using an Amazon SDK. This topic also includes information about getting started and details about previous SDK versions.