aws opsworks cli 运行 说明书并捕获说明书输出
aws opsworks cli run cookbook and capture cookbook output
我正在尝试通过 AWS opsworks cli 执行配方,它可以正常工作。问题是它返回 "DeploymentId" 作为输出。我正在执行以下命令-
aws opsworks create-deployment --stack-id c7cxxxxx-efxx-xxxx-xxxx-1dexxxxxxc78 --command {"Name":"execute_recipes", "Args":{"recipes":["cookbook::recipes"]}}
输出-
{
"DeploymentId": "824749ec-7e20-42ca-89c5-6646cf0c863c"
}
我想要获取 opsworks 实例 chef 部署输出 - 比如 -
[2017-03-14T00:06:50-04:00] INFO: Starting chef-zero on port 8889 with repository at repository at /opt/aws/opsworks/current
One version per cookbook
data_bags at /var/lib/aws/opsworks/data/data_bags
nodes at /var/lib/aws/opsworks/data/nodes
[2017-03-14T00:06:50-04:00] INFO: Forking chef instance to converge... [2017-03-14T00:06:50-04:00] INFO: *** Chef 11.10.4 *** [2017-03-14T00:06:50-04:00] INFO: Chef-client pid: 28634 [2017-03-14T00:06:50-04:00] INFO: Setting the run_list to ["opsworks_custom_cookbooks::load", "opsworks_custom_cookbooks::execute"] from JSON [2017-03-14T00:06:50-04:00] WARN: Run List override has been provided. [2017-03-14T00:06:50-04:00] WARN: Original Run List: [recipe[opsworks_custom_cookbooks::load], recipe[opsworks_custom_cookbooks::execute]]
有什么办法吗?我正在从 Jenkins 测试它并想捕获厨师日志。
感谢@Tensibai。 aws opswork describe-deployment
Link 将为您提供所需的帮助。例如-
aws opsworks describe-commands --deployment-id axxxxxxxxx-3xxxxxxx -4xxx-8xxxxx-9xxxxxxx
这会给你结果。您可以从链接的 s3 位置获取结果。
我正在尝试通过 AWS opsworks cli 执行配方,它可以正常工作。问题是它返回 "DeploymentId" 作为输出。我正在执行以下命令-
aws opsworks create-deployment --stack-id c7cxxxxx-efxx-xxxx-xxxx-1dexxxxxxc78 --command {"Name":"execute_recipes", "Args":{"recipes":["cookbook::recipes"]}}
输出-
{ "DeploymentId": "824749ec-7e20-42ca-89c5-6646cf0c863c" }
我想要获取 opsworks 实例 chef 部署输出 - 比如 -
[2017-03-14T00:06:50-04:00] INFO: Starting chef-zero on port 8889 with repository at repository at /opt/aws/opsworks/current
One version per cookbook
data_bags at /var/lib/aws/opsworks/data/data_bags
nodes at /var/lib/aws/opsworks/data/nodes
[2017-03-14T00:06:50-04:00] INFO: Forking chef instance to converge... [2017-03-14T00:06:50-04:00] INFO: *** Chef 11.10.4 *** [2017-03-14T00:06:50-04:00] INFO: Chef-client pid: 28634 [2017-03-14T00:06:50-04:00] INFO: Setting the run_list to ["opsworks_custom_cookbooks::load", "opsworks_custom_cookbooks::execute"] from JSON [2017-03-14T00:06:50-04:00] WARN: Run List override has been provided. [2017-03-14T00:06:50-04:00] WARN: Original Run List: [recipe[opsworks_custom_cookbooks::load], recipe[opsworks_custom_cookbooks::execute]]
有什么办法吗?我正在从 Jenkins 测试它并想捕获厨师日志。
感谢@Tensibai。 aws opswork describe-deployment
Link 将为您提供所需的帮助。例如-
aws opsworks describe-commands --deployment-id axxxxxxxxx-3xxxxxxx -4xxx-8xxxxx-9xxxxxxx
这会给你结果。您可以从链接的 s3 位置获取结果。