0

状态管理器文档允许我们定义类型的输入参数StringList。我们如何枚举StringList文档定义中的每个值?

例如,想象一个StringList定义了要运行的命令列表的输入参数。我们如何aws:runShellScript为列表中的每个命令创建一个新操作?

下面的伪文档显示了我想要实现的目标 - 为 a 中的每个值创建一个新操作StringList

schemaVersion: "2.2"
description: "Updates services configured for the current role"
parameters:
  ListOfCommands:
    type: "StringList"
    description: "A list of commands to execute"
mainSteps:

 /* For $C in ListOfCommands: */

  - action: "aws:runShellScript"
    name: "InstallConsul"
    inputs:
      runCommand:
      - "{{$C}}"
4

1 回答 1

1

根据 AWS 支持,目前这是不可能的。无法在文档本身的StringList中枚举任何值。

于 2018-08-17T13:40:57.957 回答