forked from aws-vls-dub/eks
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcloud9-template.yaml
51 lines (49 loc) · 1.24 KB
/
cloud9-template.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
AWSTemplateFormatVersion: 2010-09-09
Description: Create a Cloud9 environment and EC2 Admin role (create the stack in the AWS Console)
Resources:
EKSCloud9:
Type: AWS::Cloud9::EnvironmentEC2
Properties:
AutomaticStopTimeMinutes: 30
Description: "EKS Cloud9 environment"
InstanceType: t3.micro
# Name: eks-cloud9
AdminRole:
Type: "AWS::IAM::Role"
Properties:
AssumeRolePolicyDocument:
Version: "2012-10-17"
Statement:
-
Effect: "Allow"
Principal:
Service:
- "ec2.amazonaws.com"
Action:
- "sts:AssumeRole"
Path: "/"
RolePolicy:
Type: "AWS::IAM::Policy"
Properties:
PolicyName: "Admin"
PolicyDocument:
Version: "2012-10-17"
Statement:
-
Effect: "Allow"
Action: "*"
Resource: "*"
Roles:
-
Ref: "AdminRole"
AdminInstanceProfile:
Type: "AWS::IAM::InstanceProfile"
Properties:
Path: "/"
Roles:
-
Ref: "AdminRole"
Outputs:
InstanceProfile:
Description: EC2 instance profile for the Cloud9 instance
Value: !Ref "AdminInstanceProfile"