Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…nto ecs_policies
  • Loading branch information
alinabuzachis committed Jun 7, 2022
2 parents ba35199 + 225917a commit 4acd9dc
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 21 deletions.
4 changes: 3 additions & 1 deletion aws/policy/application-security.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ Statement:
- wafv2:DeleteFirewallManagerRuleGroups
- wafv2:DisassociateFirewallManager
- wafv2:UpdateIPSet
- wafv2:TagResource
Resource:
- 'arn:aws:wafv2:{{ aws_region }}:{{ aws_account_id }}:*'

Expand Down Expand Up @@ -110,6 +109,9 @@ Statement:
- waf:UpdateSqlInjectionMatchSet
- waf:UpdateWebACL
- waf:UpdateXssMatchSet
- wafv2:ListTagsForResource
- wafv2:TagResource
- wafv2:UntagResource
Resource: "*"
Condition:
StringEquals:
Expand Down
16 changes: 0 additions & 16 deletions aws/policy/compute.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -114,13 +114,6 @@ Statement:
- elasticloadbalancing:ModifyTargetGroupAttributes
- elasticloadbalancing:ModifyRule
- elasticloadbalancing:SetIpAddressType
- ecs:Describe*
- ecs:List*
- ecs:TagResource
- ecs:UntagResource
- ecs:PutAccountSetting
- ecs:RegisterTaskDefinition
- ecs:DeregisterTaskDefinition
Resource:
- "*"

Expand All @@ -131,19 +124,10 @@ Statement:
- ec2:CreateVolume
- elasticloadbalancing:CreateLoadBalancer
- elasticloadbalancing:CreateRule
- ecs:RunTask
- ecs:StartTask
- ecs:StopTask
- ecs:DeleteCluster
- ecs:CreateService
- ecs:DeleteService
- ecs:UpdateService
- ecs:UpdateCluster
Resource:
- 'arn:aws:ec2:{{ aws_region }}:{{ aws_account_id }}:volume/*'
- 'arn:aws:elasticloadbalancing:{{ aws_region }}:{{ aws_account_id }}:*'
- 'arn:aws:autoscaling:{{ aws_region }}:{{ aws_account_id }}:autoScalingGroup*'
- 'arn:aws:ecs:{{ aws_region }}:{{ aws_account_id }}:*'

- Sid: AllowGlobalResourceRestrictedActionsWhichIncurNoFees
Effect: Allow
Expand Down
7 changes: 6 additions & 1 deletion aws/policy/data-services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,14 @@ Statement:
- Sid: AllowGlobalResourceRestrictedActionsWhichIncurNoFees
Effect: Allow
Action:
- dms:AddTagsToResource
- dms:CreateReplicationSubnetGroup
- dms:DeleteEndpoint
- dms:ModifyEndpoint
- dms:DeleteReplicationSubnetGroup
- dms:ListTagsForResource
- dms:ModifyEndpoint
- dms:ModifyReplicationSubnetGroup
- dms:RemoveTagsFromResource
- dynamodb:CreateTable
- dynamodb:DeleteItem
- dynamodb:DeleteTable
Expand Down Expand Up @@ -105,7 +108,9 @@ Statement:
- rds:RestoreDBClusterFromSnapshot
- rds:RestoreDBClusterFromS3
- rds:PromoteReadReplicaDBCluster
- rds:CopyDBClusterSnapshot
Resource:
- 'arn:aws:dms:{{ aws_region }}:{{ aws_account_id }}:endpoint:*'
- 'arn:aws:dms:{{ aws_region }}:{{ aws_account_id }}:subgrp:*'
- 'arn:aws:dynamodb:{{ aws_region }}:{{ aws_account_id }}:table/*'
- 'arn:aws:elasticache:{{ aws_region }}:{{ aws_account_id }}:cluster:*'
Expand Down
6 changes: 3 additions & 3 deletions aws/policy/paas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,13 +116,13 @@ Statement:
StringLike:
lambda:FunctionArn:
- arn:aws:lambda:{{ aws_region }}:{{ aws_account_id }}:function:*

- Sid: AllowGlobalUnrestrictedResourceActionsWhichIncurFees
Effect: Allow
Action:
- ecs:CreateCluster
Resource: "*"

- Sid: AllowGlobalUnrestrictedResourceActionsWhichIncurNoFees
Effect: Allow
Action:
Expand All @@ -135,7 +135,7 @@ Statement:
- ecs:DeregisterTaskDefinition
Resource:
- "*"

- Sid: AllowGlobalRestrictedResourceActionsWhichIncurFees
Effect: Allow
Action:
Expand Down

0 comments on commit 4acd9dc

Please sign in to comment.