适用于StepFunctions的AWS CloudFormation。传递DefinitionString作为参数

时间:2018-07-18 07:27:20

标签: amazon-web-services cloud amazon-cloudformation devops aws-step-functions

我正在尝试为StepFunctions创建CloudFormation。 我想将DefinitionString作为参数传递。 json字符串很大。最大上限为4096个字节。我该如何处理参数超过上限的情况。示例模板如下所示

{
   "AWSTemplateFormatVersion" : "2010-09-09",
   "Description" : "An example template for a Step Functions state machine.",
   "Resources" : {
      "MyStateMachine" : {
         "Type" : "AWS::StepFunctions::StateMachine",
         "Properties" : {
            "StateMachineName" : "HelloWorld-StateMachine",
            "DefinitionString" : "{\"StartAt\": \"HelloWorld\", \"States\": {\"HelloWorld\": {\"Type\": \"Task\", \"Resource\": \"arn:aws:lambda:us-east-1:111122223333:function:HelloFunction\", \"End\": true}}}",
            "RoleArn" : "arn:aws:iam::111122223333:role/service-role/StatesExecutionRole-us-east-1"
         }
      }
   }
}

0 个答案:

没有答案