Skip to content

Commit

Permalink
Merge pull request #16 from neilramsay/iam
Browse files Browse the repository at this point in the history
IAM Cloud Formation Syntax
  • Loading branch information
beaknit committed May 21, 2015
2 parents 09785b8 + 66bda04 commit 5a920f6
Show file tree
Hide file tree
Showing 7 changed files with 112 additions and 0 deletions.
16 changes: 16 additions & 0 deletions iam-accesskey.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<snippet>
<content><![CDATA[
"${1:iamAccessKey}": {
"Type": "AWS::IAM::AccessKey",
"Properties": {
"Status": "${2}",
"UserName": "${3}",
"Serial": "${4}"
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-accesskey</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>
15 changes: 15 additions & 0 deletions iam-group.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<snippet>
<content><![CDATA[
"${1:iamGroup}": {
"Type": "AWS::IAM::Group",
"Properties": {
"Path": "${2}",
"Policies": [ "${3}" ]
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-group</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>
15 changes: 15 additions & 0 deletions iam-instanceprofile.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<snippet>
<content><![CDATA[
"${1:iamInstanceProfile}": {
"Type": "AWS::IAM::InstanceProfile",
"Properties": {
"Path": "${2:/}",
"Roles": [ "${3}" ]
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-instanceprofile</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>
18 changes: 18 additions & 0 deletions iam-policy.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<snippet>
<content><![CDATA[
"${1:iamPolicy}": {
"Type": "AWS::IAM::Policy",
"Properties": {
"Groups" : [ "${2}" ],
"PolicyDocument" : {${3}},
"PolicyName" : "${4}",
"Roles" : [ "${5}" ],
"Users" : [ "${6}" ]
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-policy</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>
16 changes: 16 additions & 0 deletions iam-role.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<snippet>
<content><![CDATA[
"${1:iamRole}": {
"Type": "AWS::IAM::Role",
"Properties": {
"AssumeRolePolicyDocument": { ${2} },
"Path": "${3}",
"Policies": [ ${4} ]
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-role</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>
17 changes: 17 additions & 0 deletions iam-user.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<snippet>
<content><![CDATA[
"${1:iamUser}": {
"Type": "AWS::IAM::User",
"Properties": {
"Path": "${2:/}",
"Groups": [ "${3}" ],
"LoginProfile": { "Password" : "${4}" },
"Policies": [ ${5} ]
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-user</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>
15 changes: 15 additions & 0 deletions iam-usertogroupaddition.sublime-snippet
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<snippet>
<content><![CDATA[
"${1:iamUserToGroupAddition}": {
"Type": "AWS::IAM::UserToGroupAddition",
"Properties": {
"GroupName": "${2}",
"Users": [ "${3}" ]
}
}
]]></content>
<!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
<tabTrigger>iam-usertogroupaddition</tabTrigger>
<!-- Optional: Set a scope to limit where the snippet will trigger -->
<scope>source.cloudformation</scope>
</snippet>

0 comments on commit 5a920f6

Please sign in to comment.