

本文属于机器翻译版本。若本译文内容与英语原文存在差异，则一律以英文原文为准。

# 更改加速警报配置
<a name="acc-mem-change-am"></a>

要添加或更新新的警报定义，您可以部署配置文档[CloudFormation 用于部署加速配置更改](acc-mem-deploy-change-cfn.md)或调用 [CreateHostedConfigurationVersion](https://docs.aws.amazon.com/appconfig/2019-10-09/APIReference/API_CreateHostedConfigurationVersion.html)API。

这是一个 Linux 命令行命令，它在 base64 中生成参数值，这正是 AppConfig CLI 命令所期望的。有关信息，请参阅 AWS CLI 文档 B [inary/Blob（二进制](https://docs.aws.amazon.com/cli/latest/userguide/cli-usage-parameters-types.html#parameter-type-blob)大对象）。

例如：

```
aws appconfig create-hosted-configuration-version --application-id application-id --configuration-profile-id configuration-profile-id --content base64-string 
      --content-type application/json
```
+ **应用程序 ID：**应用程序 AMS 的 ID AlarmManager；您可以通过 [ListApplications](https://docs.aws.amazon.com/appconfig/2019-10-09/APIReference/API_ListApplications.html)API 调用找到这一点。
+ **配置文件 ID**：配置的 ID CustomerManagedAlarms；您可以通过 [ListConfigurationProfiles](https://docs.aws.amazon.com/appconfig/2019-10-09/APIReference/API_ListConfigurationProfiles.html)API 调用找到这一点。
+ **内容：内容**[的 Base64 字符串，将通过创建文档并将其编码为 base64 来创建：cat alarms-v2.json \$1 base64（参见 Binary/Blob（二进制大对象））。](https://docs.aws.amazon.com/cli/latest/userguide/cli-usage-parameters-types.html#parameter-type-blob)

  **内容类型**：MIME 类型，`application/json`因为警报定义是用 JSON 编写的。

**重要**  
将[StartDeployment](https://docs.aws.amazon.com/appconfig/2019-10-09/APIReference/API_StartDeployment.html)和 [StopDeployment](https://docs.aws.amazon.com/appconfig/2019-10-09/APIReference/API_StopDeployment.html)API 操作的访问权限限制为了解向目标部署新配置的责任和后果的可信用户。

要详细了解如何使用 AWS AppConfig 功能创建和部署配置，请参阅[使用 AWS AppConfig](https://docs.aws.amazon.com/appconfig/latest/userguide/appconfig-working.html)。