Created
November 22, 2021 16:22
-
-
Save schosterbarak/c6c3738ceff6b065acc36a2025cfea3a to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| AWSTemplateFormatVersion: 2010-09-09 | |
| Description: IAM policy | |
| Resources: | |
| ExamplePolicy: | |
| Type: 'AWS::IAM::Policy' | |
| Properties: | |
| PolicyName: root | |
| PolicyDocument: | |
| Version: 2012-10-17 | |
| Statement: | |
| - Effect: Allow | |
| Action: | |
| - "iam:PassRole" | |
| - "lambda:CreateFunction" | |
| - "lambda:CreateEventSourceMapping" | |
| - "dynamodb:CreateTable" | |
| - "dynamodb:PutItem" | |
| Resource: '*' |
This file contains hidden or 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
| provider: | |
| name: aws | |
| runtime: nodejs10.x | |
| resources: | |
| Resources: | |
| ExamplePolicy: | |
| Type: 'AWS::IAM::Policy' | |
| Properties: | |
| PolicyName: root | |
| PolicyDocument: | |
| Version: 2012-10-17 | |
| Statement: | |
| - Effect: Allow | |
| Action: | |
| - "iam:PassRole" | |
| - "lambda:CreateFunction" | |
| - "lambda:CreateEventSourceMapping" | |
| - "dynamodb:CreateTable" | |
| - "dynamodb:PutItem" | |
| Resource: '*' |
This file contains hidden or 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
| data "aws_iam_policy_document" "example" { | |
| statement { | |
| sid = "1" | |
| effect = "Allow" | |
| actions = [ | |
| "iam:PassRole", | |
| "lambda:CreateFunction", | |
| "lambda:CreateEventSourceMapping", | |
| "dynamodb:CreateTable", | |
| "dynamodb:PutItem", | |
| ] | |
| resources = [ | |
| "*", | |
| ] | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment