

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

# Lambda 挂钩
<a name="lambda-hooks"></a>

要在您的账户中使用 AWS Lambda 挂钩，您必须先为要使用该挂钩的账户和区域*激活*挂钩。激活 Hook 后，它可以在激活该挂钩的账户和区域的堆栈操作中使用。

激活 Lambda 挂钩时， CloudFormation 会在账户的注册表中为已激活的挂钩创建一个条目作为私有挂钩。这允许您设置 Hook 包含的任何配置属性。配置属性定义了如何为给定 AWS 账户 和区域配置挂钩。

**Topics**
+ [AWS CLI 用于使用 Lambda 挂钩的命令](#commonly-used-commands-lambda-hooks)
+ [创建 Lambda 函数来评估 Lambda 挂钩的资源](lambda-hooks-create-lambda-function.md)
+ [准备创建 Lambda 挂钩](lambda-hooks-prepare-to-create-hook.md)
+ [在您的账户中激活 Lambda 挂钩](lambda-hooks-activate-hooks.md)
+ [查看您账户中 Lambda 挂钩的日志](lambda-hooks-view-logs.md)
+ [删除账户中的 Lambda 挂钩](lambda-hooks-delete-hooks.md)

## AWS CLI 用于使用 Lambda 挂钩的命令
<a name="commonly-used-commands-lambda-hooks"></a>

使用 Lambda 挂钩的 AWS CLI 命令包括：
+ [https://docs.aws.amazon.com/cli/latest/reference/cloudformation/activate-type.html](https://docs.aws.amazon.com/cli/latest/reference/cloudformation/activate-type.html)启动 Lambda 挂钩的激活过程。
+ [https://docs.aws.amazon.com/cli/latest/reference/cloudformation/set-type-configuration.html](https://docs.aws.amazon.com/cli/latest/reference/cloudformation/set-type-configuration.html)为账户中的 Hook 指定配置数据。
+ [https://docs.aws.amazon.com/cli/latest/reference/cloudformation/list-types.html](https://docs.aws.amazon.com/cli/latest/reference/cloudformation/list-types.html)列出你账户中的 Hook。
+ [https://docs.aws.amazon.com/cli/latest/reference/cloudformation/describe-type.html](https://docs.aws.amazon.com/cli/latest/reference/cloudformation/describe-type.html)返回有关特定 Hook 或特定 Hook 版本的详细信息，包括当前配置数据。
+ [https://docs.aws.amazon.com/cli/latest/reference/cloudformation/deactivate-type.html](https://docs.aws.amazon.com/cli/latest/reference/cloudformation/deactivate-type.html)从您的账户中移除之前激活的 Hook。