forked from VirtusLab/kubedrainer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathiam.yaml
36 lines (35 loc) · 979 Bytes
/
iam.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
AWSTemplateFormatVersion: '2010-09-09'
Resources:
IAMRoleKubedrainer:
Type: AWS::IAM::Role
Properties:
RoleName: kubedrainer
Path: "/"
AssumeRolePolicyDocument:
Version: "2012-10-17"
Statement:
- Action:
- sts:AssumeRole
Effect: Allow
Principal:
Service:
- ec2.amazonaws.com
- Action:
- sts:AssumeRole
Effect: Allow
Principal:
AWS:
- <Kubernetes Node IAM Role>
Policies:
- PolicyName: root
PolicyDocument:
Version: "2012-10-17"
Statement:
- Sid: AllowAutoscalingLifehookManagement
Effect: "Allow"
Action:
- autoscaling:CompleteLifecycleAction
- autoscaling:DescribeAutoScalingGroups
- autoscaling:DescribeAutoScalingInstances
- autoscaling:DescribeLifecycleHooks
Resource: "*"