如何使用 CFT 启动具有 CreditSpecification 的 Spot 车队?

How to launch Spot fleet with CreditSpecification using CFT?

我正在为我的 spot 队列使用 t3a.large 实例,但是我无法在 CreditSpecifications=standard 模式下启动 spot 队列以节省成本。谁能告诉我如何在 CFT 中实现这一点?

不是:对于 EC2,我们要设置此 CFT 属性

https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ec2-instance-creditspecification.html

对于 spot 车队,我认为您需要在启动模板中设置该选项:AWS::EC2::LaunchTemplate CreditSpecification