可以将List <S3Target>作为输入传递给Cloud Formation吗?

时间:2019-12-30 19:07:02

标签: amazon-web-services amazon-s3 amazon-cloudformation aws-glue

我有一个AWS::Glue::Crawler资源以cloudformation的形式定义,如下所示:

# ...

Parameters:
  pS3Targets:
    Type: List<AWS::Glue::Crawler::S3Target>  # <-- I want this. This does not appear to be supported

Resources:

# ...

  rCrawler:
    Type: AWS::Glue::Crawler
    Properties:
      Name: "my_crawler"
      DatabaseName: "my_db"
      Role: !GetAtt myRole.Arn
      Schedule:
        ScheduleExpression: !Ref pCrawlerSchedule
      Targets:
        # TODO: parameterize the List of S3Targets
        S3Targets:
          - Path: !Sub "s3://my-bucket/table1/"
          - Path: !Sub "s3://my-bucket/table2/"
          - Path: !Sub "s3://my-bucket/table3/"
          - Path: !Sub "s3://my-bucket/tableN/"

我希望能够将可变数量的S3路径(S3Target类型)传递给cloudformation模板。这可能吗?

0 个答案:

没有答案