-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Test event added; scripts README => running notes
- Loading branch information
1 parent
fcecb10
commit 7a98452
Showing
5 changed files
with
47 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Running Notes | ||
|
||
## SAM CLI Limitation | ||
|
||
Due to a [limitation](https://github.com/aws/aws-sam-cli/issues/1701), `sam deploy` requires either: | ||
- `--s3-bucket` command line argument OR | ||
- It needs to be run for the first time with `--guided` or `-g` flags. SAM creates a S3 bucket during guided run. | ||
|
||
Once you have the S3 bucket to upload your code to, you may - | ||
- Add it to samconfig TOML files as `s3_bucket = "<aws-sam-cli-managed-default-samclisourcebucket-...>"` OR | ||
- Add a `--s3-bucket <aws-sam-cli-managed-default-samclisourcebucket-...>` argument to `sam deploy` commands in `1-deploy.sh` script. | ||
|
||
## Invoking Lambda functions from CLI | ||
|
||
``` | ||
aws lambda invoke --function-name getAwsDocsRepo \ | ||
getAwsDocsRepo-response.json | ||
``` | ||
|
||
``` | ||
aws lambda invoke --function-name unzipRepoArchive \ | ||
unzipRepoArchive-response.json \ | ||
--cli-binary-format raw-in-base64-out \ | ||
--payload "$(< test-events/unzip-repo-archive-test-event.json)" | ||
``` | ||
|
||
### Note | ||
|
||
- Above commands invoke Lambda synchronously. So any async destination will not get invocation record. | ||
- Add `--invocation-type Event` clause to invoke Lambda asynchronously. |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"Records": [ | ||
{ | ||
"s3": { | ||
"bucket": { | ||
"name": "0fef02b1-1c46-435a-a0e7-945a233f19a6" | ||
}, | ||
"object": { | ||
"key": "aws-cloudformation-user-guide.zip" | ||
} | ||
} | ||
} | ||
] | ||
} |