Cloudformation 不会改回我手动修改的设置
Cloudformation doesn't change back a setting I manually modified
试图更好地理解 CF 行为。
我有一个定义 ECS 服务的模板:
ECSService:
Type: AWS::ECS::Service
Properties:
Cluster: mycluster
...
DesiredCount: 2
我转到 CF 创建的服务并将 DesiredCount 设置为 0。
然后我再次部署 CF 模板,但它没有将 DesiredCount 改回 2。
为什么它不断言完整配置?
您正在寻找的功能称为 "Drift Detection"。
此功能还不是 CloudFormation 的一部分,但目前处于测试阶段,计划于 2018 年发布,according to Amazon。
通常最好不要修改由 Cloudformation 堆栈管理的资源。如果您需要更新资源,请执行堆栈更新。
更新(11/19):好消息! AWS 已发布此功能:https://aws.amazon.com/blogs/aws/new-cloudformation-drift-detection/
试图更好地理解 CF 行为。
我有一个定义 ECS 服务的模板:
ECSService:
Type: AWS::ECS::Service
Properties:
Cluster: mycluster
...
DesiredCount: 2
我转到 CF 创建的服务并将 DesiredCount 设置为 0。
然后我再次部署 CF 模板,但它没有将 DesiredCount 改回 2。
为什么它不断言完整配置?
您正在寻找的功能称为 "Drift Detection"。
此功能还不是 CloudFormation 的一部分,但目前处于测试阶段,计划于 2018 年发布,according to Amazon。
通常最好不要修改由 Cloudformation 堆栈管理的资源。如果您需要更新资源,请执行堆栈更新。
更新(11/19):好消息! AWS 已发布此功能:https://aws.amazon.com/blogs/aws/new-cloudformation-drift-detection/