Skip to content
This repository has been archived by the owner on Jan 6, 2022. It is now read-only.

Commit

Permalink
Merge pull request #4 from ImmobilienScout24/feature/integration_test…
Browse files Browse the repository at this point in the history
…_arn

adding the role that can be assumed during integration test
  • Loading branch information
sdomme committed Nov 23, 2015
2 parents 56f3658 + 792d5e8 commit 9bb69bd
Show file tree
Hide file tree
Showing 4 changed files with 37 additions and 1 deletion.
1 change: 1 addition & 0 deletions build.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ def set_properties(project):
project.set_property('template_files',
[
('cfn-sphere/templates','crassus.yaml'),
('cfn-sphere/templates','crassus_integration_test_role.yaml'),
])

project.set_property('distutils_classifiers', [
Expand Down
12 changes: 12 additions & 0 deletions cfn-sphere/crassus-stack-with-integration-test-support.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
region: eu-west-1
stacks:
crassus:
template-url: templates/crassus.yaml
parameters:
zipFile: latest/crassus.zip
bucketName: crassus-lambda-zips <Bucket Policy is set to Requester Pays>
triggeringUserArn: <user/role ARN which will trigger deployment via CRASSUS">
crassus-integrationTest-role:
template-url: templates/crassus_integration_test_role.yaml
parameters:
integrationTestArn: <role ARN which should be able to assume the integration-test role>
2 changes: 1 addition & 1 deletion cfn-sphere/templates/crassus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -177,4 +177,4 @@ Resources:
Resource: "*"
Queues:
-
Ref: outputSqsQueue
Ref: outputSqsQueue
23 changes: 23 additions & 0 deletions cfn-sphere/templates/crassus_integration_test_role.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
AWSTemplateFormatVersion: '2010-09-09'
Description: crassus role to support integration tests
Parameters:
integrationTestArn:
AllowedPattern: arn:aws:iam::[0-9]{12}:[\S]+
ConstraintDescription: must be a valid Amazon Resource Name e.g. arn:aws:iam::123456789012:role/cld-chain
Description: role ARN which should be able to assume the integration-test role>
Type: String
Resources:
integrationTestRole:
Type: AWS::IAM::Role
Properties:
ManagedPolicyArns: ['arn:aws:iam::aws:policy/AdministratorAccess']
AssumeRolePolicyDocument:
Statement:
- Action:
- sts:AssumeRole
Effect: Allow
Principal:
AWS:
Ref: integrationTestArn
Version: '2012-10-17'

0 comments on commit 9bb69bd

Please sign in to comment.