doc: Added more doc
This commit is contained in:
+3
-2
@@ -1,10 +1,10 @@
|
|||||||
schemaVersion: '0.3'
|
schemaVersion: '0.3'
|
||||||
mainSteps:
|
mainSteps:
|
||||||
|
# ssm parameter supports StringList, which is comma separated strings (i.e. 111111111111,222222222222)
|
||||||
- name: GetParameter
|
- name: GetParameter
|
||||||
action: aws:executeAwsApi
|
action: aws:executeAwsApi
|
||||||
nextStep: ConvertInputToList
|
nextStep: ConvertInputToList
|
||||||
isEnd: false
|
isEnd: false
|
||||||
# parameter contains comma separated ids (i.e. 111111111111,222222222222)
|
|
||||||
inputs:
|
inputs:
|
||||||
Service: ssm
|
Service: ssm
|
||||||
Api: GetParameter
|
Api: GetParameter
|
||||||
@@ -13,7 +13,8 @@ mainSteps:
|
|||||||
- Name: Accounts
|
- Name: Accounts
|
||||||
Selector: $.Parameter.Value
|
Selector: $.Parameter.Value
|
||||||
Type: String
|
Type: String
|
||||||
# input needs to be transformed to a list of string in order to be used by aws:loop
|
# The so-called StringList needs to be transformed to a list[str] in order to be used by aws:loop
|
||||||
|
# There is no native action for that, and I need to use python
|
||||||
- name: ConvertInputToList
|
- name: ConvertInputToList
|
||||||
action: aws:executeScript
|
action: aws:executeScript
|
||||||
nextStep: Loop
|
nextStep: Loop
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
schemaVersion: '0.3'
|
schemaVersion: '0.3'
|
||||||
mainSteps:
|
mainSteps:
|
||||||
|
# Using executeAwsApi, I can get a list[str] which can then be iterated by aws:loop
|
||||||
- name: ListAccounts
|
- name: ListAccounts
|
||||||
action: aws:executeAwsApi
|
action: aws:executeAwsApi
|
||||||
nextStep: Loop
|
nextStep: Loop
|
||||||
|
|||||||
@@ -1,3 +1,11 @@
|
|||||||
# aws.ssm.documents
|
# aws.ssm.documents
|
||||||
|
|
||||||
AWS SSM document examples
|
## AWS SSM automation document examples
|
||||||
|
SSM automation document uses schema version 0.3, which is very primitive. Step function is probably a better way to go
|
||||||
|
|
||||||
|
| File | Description |
|
||||||
|
|---------------------------------------|---------------------------------------------------------------------------------------|
|
||||||
|
| OrgAccountsPrint.yaml | Use executeApi to list accounts then print with aws:loop |
|
||||||
|
| LoopWithCsv.yaml | Get value from ssm parameter store then print with aws:loop |
|
||||||
|
| ListCloudtrailsInMemberAccounts.yaml | Loop through a list of accounts, assume role into the account and describe cloudtrail |
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user