

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# `pcluster get-image-stack-events`
<a name="pcluster.get-image-stack-events-v3"></a>

針對指定的映像建置，擷取與堆疊相關聯的事件。

```
pcluster get-image-stack-events [-h] 
                 --image-id IMAGE_ID
                [--debug]
                [--next-token NEXT_TOKEN]
                [--query QUERY]
                [--region REGION]
```

## 具名引數
<a name="pcluster-v3.get-image-stack-events.namedargs"></a>

**-h, --help**  
顯示 的說明文字`pcluster get-image-stack-events`。

**--image-id, -i *IMAGE\$1ID***  
指定映像的 ID。

**--debug**  
啟用偵錯記錄。

**--next-token *NEXT\$1TOKEN***  
下一組結果的字符。

**--query *QUERY***  
指定要在輸出上執行的 JMESPath 查詢。

**--region, -r *REGION***  
指定 AWS 區域 要使用的 。 AWS 區域 必須使用 `AWS_DEFAULT_REGION`環境變數、 `~/.aws/config` 檔案 `[default]`區段中的 `region`設定或 `--region` 參數來指定 。

**使用 3.1.2 AWS ParallelCluster 版的範例：**

```
$ pcluster get-image-stack-events --image-id custom-alinux2-image --region us-east-1 --query "events[0]"
   {
  "eventId": "ParallelClusterImage-CREATE_IN_PROGRESS-2022-04-05T21:39:24.725Z",
  "physicalResourceId": "arn:aws:imagebuilder:us-east-1:123456789012:image/parallelclusterimage-custom-alinux2-image/3.1.2/1",
  "resourceStatus": "CREATE_IN_PROGRESS",
  "resourceStatusReason": "Resource creation Initiated",
  "resourceProperties": "{\"InfrastructureConfigurationArn\":\"arn:aws:imagebuilder:us-east-1:123456789012:infrastructure-configuration/parallelclusterimage-1234abcd-56ef-78gh-90ij-abcd1234efgh\",\"ImageRecipeArn\":\"arn:aws:imagebuilder:us-east-1:123456789012:image-recipe/parallelclusterimage-custom-alinux2-image/3.1.2\",\"DistributionConfigurationArn\":\"arn:aws:imagebuilder:us-east-1:123456789012:distribution-configuration/parallelclusterimage-1234abcd-56ef-78gh-90ij-abcd1234efgh\",\"EnhancedImageMetadataEnabled\":\"false\",\"Tags\":{\"parallelcluster:image_name\":\"custom-alinux2-image\",\"parallelcluster:image_id\":\"custom-alinux2-image\"}}",
  "stackId": "arn:aws:cloudformation:us-east-1:123456789012:stack/custom-alinux2-image/1234abcd-56ef-78gh-90ij-abcd1234efgh",
  "stackName": "custom-alinux2-image",
  "logicalResourceId": "ParallelClusterImage",
  "resourceType": "AWS::ImageBuilder::Image",
  "timestamp": "2022-04-05T21:39:24.725Z"
}
```