Skip to content

Commit e5a34cd

Browse files
author
Lambros Petrou
authored
Merge pull request #4 from aws-cloudformation/update-readme
Update README with instructions to use latest version when testing
2 parents e32403c + f117def commit e5a34cd

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

aws-codeguruprofiler-profilinggroup/README.md

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,21 @@ pre-commit run --all-files && AWS_REGION=us-east-1 mvn clean package
3434
```
3535
cfn submit -v --region us-east-1
3636
```
37-
2. Create a sample CloudFormation stack that defines a profiling group:
37+
2. Update the default version used by CloudFormation:
38+
```
39+
# Get the latest version in your account
40+
Arn=`aws cloudformation list-type-versions --region us-east-1 --type RESOURCE --type-name "AWS::CodeGuruProfiler::ProfilingGroup" | jq '.TypeVersionSummaries[].Arn' | sort -nr | head -n 1 | tr -d '"'`
41+
42+
# Update the default version used by CloudFormation
43+
aws cloudformation set-type-default-version --region us-east-1 --arn "$Arn"
44+
```
45+
3. Create a sample CloudFormation stack that defines a profiling group:
3846
```
3947
aws cloudformation create-stack --region us-east-1 --template-body "file://sample-template.json" --stack-name "sample-profiling-group-resource-creation"
4048
```
41-
3. Validate the creation of the profiling group!
42-
4. Delete the sample stack:
49+
4. Validate the creation of the profiling group!
50+
5. Delete the sample stack:
4351
```
4452
aws cloudformation delete-stack --region us-east-1 --stack-name "sample-profiling-group-resource-creation"
4553
```
46-
5. Validate the profiling group has been deleted!
54+
6. Validate the profiling group has been deleted!

0 commit comments

Comments
 (0)