File tree Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Expand file tree Collapse file tree 1 file changed +49
-0
lines changed Original file line number Diff line number Diff line change
1
+ var cf = require ( '@mapbox/cloudfriend' ) ;
2
+
3
+ module . exports = {
4
+ AWSTemplateFormatVersion : '2010-09-09' ,
5
+ Resources : {
6
+ User : {
7
+ Type : 'AWS::IAM::User' ,
8
+ Properties : {
9
+ Policies : [
10
+ {
11
+ PolicyName : 'List-objects-in-S3-bucket' ,
12
+ PolicyDocument : {
13
+ Statement : [
14
+ {
15
+ Action : [
16
+ 's3:GetObject' ,
17
+ 's3:GetObjectAcl' ,
18
+ 's3:ListBucket' ,
19
+ 's3:ListAllMyBuckets'
20
+ ] ,
21
+ Effect : 'Allow' ,
22
+ Resource : [
23
+ 'arn:aws:s3:::mapbox/*'
24
+ ] ,
25
+ Condition : {
26
+ StringLike : {
27
+ 's3:prefix' : '/vision/travis/ios-builds*'
28
+ }
29
+ }
30
+ }
31
+ ]
32
+ }
33
+ }
34
+ ]
35
+ }
36
+ } ,
37
+ AccessKey : {
38
+ Type : 'AWS::IAM::AccessKey' ,
39
+ Properties : {
40
+ UserName : cf . ref ( 'User' )
41
+ }
42
+ }
43
+ } ,
44
+ Outputs : {
45
+ AccessKeyId : { Value : cf . ref ( 'AccessKey' ) } ,
46
+ SecretAccessKey : { Value : cf . getAtt ( 'AccessKey' , 'SecretAccessKey' ) }
47
+ }
48
+ } ;
49
+
You can’t perform that action at this time.
0 commit comments