使用 CodeBuild 的 Amazon Config 示例
Amazon Config 提供了您的 Amazon 资源的清单以及这些资源的配置更改历史记录。Amazon Config 现在支持 Amazon CodeBuild 作为 Amazon 资源,这意味着该服务可以跟踪您的 CodeBuild 项目。有关 Amazon Config 的更多信息,请参阅《Amazon Config 开发人员指南》中的什么是 Amazon Config?。
您可以在 Amazon Config 控制台中的资源库存页面上查看有关 CodeBuild 资源的以下信息:
-
您的 CodeBuild 配置更改的时间线。
-
每个 CodeBuild 项目的配置详细信息。
-
与其他 Amazon 资源的关系。
-
您的 CodeBuild 项目的更改列表。
将 CodeBuild 与 Amazon Config 结合使用
本主题中的过程展示了如何设置 Amazon Config 以及如何查找 CodeBuild 项目。
先决条件
创建 Amazon CodeBuild 项目。有关说明,请参阅创建构建项目。
步骤 1:设置 Amazon Config
注意
完成设置后,可能需要等待最多 10 分钟,之后才能在 Amazon CodeBuild 控制台中看到 Amazon Config 项目。
步骤 2:查找 Amazon CodeBuild 项目
-
登录 Amazon 管理控制台,然后通过以下网址打开 Amazon Config 控制台:https://console.aws.amazon.com/config
。 -
在资源清单页面上,选择资源类型下的 Amazon CodeBuild 项目。向下滚动并选中 CodeBuild 项目复选框。
-
选择查找。
-
添加 CodeBuild 项目列表后,选择配置时间线列中的 CodeBuild 项目名称链接。
步骤 3:在 Amazon Config 控制台中查看 Amazon CodeBuild 数据
在资源清单页面上查找资源时,可选择 Amazon Config 时间线以查看有关您的 CodeBuild 项目的详细信息。资源的详细信息页面提供了有关该资源的配置、关系和更改次数的信息。
页面顶部的块统称为时间线。时间线显示了记录的创建日期和时间。
有关更多信息,请参阅《Amazon Config 开发人员指南》中的在 Amazon Config 控制台中查看配置详细信息。