-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into tmp/schema/6409742986/1
- Loading branch information
Showing
9 changed files
with
473 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
tests/translator/input/state_machine_with_schedule_role.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
Resources: | ||
|
||
MyStateMachine: | ||
Type: AWS::Serverless::StateMachine | ||
|
||
Properties: | ||
DefinitionUri: s3://sam-demo-bucket/my_state_machine.asl.json | ||
Events: | ||
CWSchedule: | ||
Type: Schedule | ||
Properties: | ||
Schedule: rate(1 minute) | ||
Description: test schedule | ||
Enabled: false | ||
RoleArn: arn:0000000000:iam::role/yoyo | ||
CWScheduleCreateRole: | ||
Type: Schedule | ||
Properties: | ||
Schedule: rate(1 minute) | ||
Description: test schedule | ||
Enabled: false |
129 changes: 129 additions & 0 deletions
129
tests/translator/output/aws-cn/state_machine_with_schedule_role.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,129 @@ | ||
{ | ||
"Resources": { | ||
"MyStateMachine": { | ||
"Properties": { | ||
"DefinitionS3Location": { | ||
"Bucket": "sam-demo-bucket", | ||
"Key": "my_state_machine.asl.json" | ||
}, | ||
"RoleArn": { | ||
"Fn::GetAtt": [ | ||
"MyStateMachineRole", | ||
"Arn" | ||
] | ||
}, | ||
"Tags": [ | ||
{ | ||
"Key": "stateMachine:createdBy", | ||
"Value": "SAM" | ||
} | ||
] | ||
}, | ||
"Type": "AWS::StepFunctions::StateMachine" | ||
}, | ||
"MyStateMachineCWSchedule": { | ||
"Properties": { | ||
"Description": "test schedule", | ||
"ScheduleExpression": "rate(1 minute)", | ||
"State": "DISABLED", | ||
"Targets": [ | ||
{ | ||
"Arn": { | ||
"Ref": "MyStateMachine" | ||
}, | ||
"Id": "MyStateMachineCWScheduleStepFunctionsTarget", | ||
"RoleArn": "arn:0000000000:iam::role/yoyo" | ||
} | ||
] | ||
}, | ||
"Type": "AWS::Events::Rule" | ||
}, | ||
"MyStateMachineCWScheduleCreateRole": { | ||
"Properties": { | ||
"Description": "test schedule", | ||
"ScheduleExpression": "rate(1 minute)", | ||
"State": "DISABLED", | ||
"Targets": [ | ||
{ | ||
"Arn": { | ||
"Ref": "MyStateMachine" | ||
}, | ||
"Id": "MyStateMachineCWScheduleCreateRoleStepFunctionsTarget", | ||
"RoleArn": { | ||
"Fn::GetAtt": [ | ||
"MyStateMachineCWScheduleCreateRoleRole", | ||
"Arn" | ||
] | ||
} | ||
} | ||
] | ||
}, | ||
"Type": "AWS::Events::Rule" | ||
}, | ||
"MyStateMachineCWScheduleCreateRoleRole": { | ||
"Properties": { | ||
"AssumeRolePolicyDocument": { | ||
"Statement": [ | ||
{ | ||
"Action": [ | ||
"sts:AssumeRole" | ||
], | ||
"Effect": "Allow", | ||
"Principal": { | ||
"Service": [ | ||
"events.amazonaws.com" | ||
] | ||
} | ||
} | ||
], | ||
"Version": "2012-10-17" | ||
}, | ||
"Policies": [ | ||
{ | ||
"PolicyDocument": { | ||
"Statement": [ | ||
{ | ||
"Action": "states:StartExecution", | ||
"Effect": "Allow", | ||
"Resource": { | ||
"Ref": "MyStateMachine" | ||
} | ||
} | ||
] | ||
}, | ||
"PolicyName": "MyStateMachineCWScheduleCreateRoleRoleStartExecutionPolicy" | ||
} | ||
] | ||
}, | ||
"Type": "AWS::IAM::Role" | ||
}, | ||
"MyStateMachineRole": { | ||
"Properties": { | ||
"AssumeRolePolicyDocument": { | ||
"Statement": [ | ||
{ | ||
"Action": [ | ||
"sts:AssumeRole" | ||
], | ||
"Effect": "Allow", | ||
"Principal": { | ||
"Service": [ | ||
"states.amazonaws.com" | ||
] | ||
} | ||
} | ||
], | ||
"Version": "2012-10-17" | ||
}, | ||
"ManagedPolicyArns": [], | ||
"Tags": [ | ||
{ | ||
"Key": "stateMachine:createdBy", | ||
"Value": "SAM" | ||
} | ||
] | ||
}, | ||
"Type": "AWS::IAM::Role" | ||
} | ||
} | ||
} |
Oops, something went wrong.