describe_fleet_instances

describe_fleet_instances(**kwargs)

Describes the running instances for the specified EC2 Fleet.

For more information, see Monitor your EC2 Fleet in the Amazon EC2 User Guide .

See also: AWS API Documentation

Request Syntax

response = client.describe_fleet_instances(
    DryRun=True|False,
    MaxResults=123,
    NextToken='string',
    FleetId='string',
    Filters=[
        {
            'Name': 'string',
            'Values': [
                'string',
            ]
        },
    ]
)
Parameters
  • DryRun (boolean) -- Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation . Otherwise, it is UnauthorizedOperation .
  • MaxResults (integer) -- The maximum number of items to return for this request. To get the next page of items, make another request with the token returned in the output. For more information, see Pagination.
  • NextToken (string) -- The token returned from a previous paginated request. Pagination continues from the end of the items returned by the previous request.
  • FleetId (string) --

    [REQUIRED]

    The ID of the EC2 Fleet.

  • Filters (list) --

    The filters.

    • instance-type - The instance type.
    • (dict) --

      A filter name and value pair that is used to return a more specific list of results from a describe operation. Filters can be used to match a set of resources by specific criteria, such as tags, attributes, or IDs.

      If you specify multiple filters, the filters are joined with an AND , and the request returns only results that match all of the specified filters.

      • Name (string) --

        The name of the filter. Filter names are case-sensitive.

      • Values (list) --

        The filter values. Filter values are case-sensitive. If you specify multiple values for a filter, the values are joined with an OR , and the request returns all results that match any of the specified values.

        • (string) --
Return type

dict

Returns

Response Syntax

{
    'ActiveInstances': [
        {
            'InstanceId': 'string',
            'InstanceType': 'string',
            'SpotInstanceRequestId': 'string',
            'InstanceHealth': 'healthy'|'unhealthy'
        },
    ],
    'NextToken': 'string',
    'FleetId': 'string'
}

Response Structure

  • (dict) --

    • ActiveInstances (list) --

      The running instances. This list is refreshed periodically and might be out of date.

      • (dict) --

        Describes a running instance in a Spot Fleet.

        • InstanceId (string) --

          The ID of the instance.

        • InstanceType (string) --

          The instance type.

        • SpotInstanceRequestId (string) --

          The ID of the Spot Instance request.

        • InstanceHealth (string) --

          The health status of the instance. If the status of either the instance status check or the system status check is impaired , the health status of the instance is unhealthy . Otherwise, the health status is healthy .

    • NextToken (string) --

      The token to include in another request to get the next page of items. This value is null when there are no more items to return.

    • FleetId (string) --

      The ID of the EC2 Fleet.