aws-cloudformation / aws-cloudformation/cloudformation-cli-go-plugin
[Question] CloudWatch logging and test-type execution
- Dominant language
- Go
- Stars
- 53
- Forks
- 31
- PR merge metrics
- No merged PRs in 30d
Description
I have CloudWatch logging working for my private Custom Resources when they're used by a Stack. Works fine.
I'd like to publish these Resources publicly but I've got a weird error trying to run `test-type` in different regions- works in some regions but not others. I'm unable to get any Custom Resource logs. The best I can tell:
1. `test-type` spins-up an (EC2?) instance and then executes `cfn test` with a local SAM Lambda
If #1 is correct then [this line](https://github.com/aws-cloudformation/cloudformation-cli-go-plugin/blob/fc208d1da48a82f84cc3741b71bf5e467f0e07ec/cfn/logging/cloudwatchlogs.go#L38) is probably why I'm not seeing CloudWatch logs.
If we get past that there may be a further issue as `cfn test` isn't passing any of the `credential` or `log` values in the Event's Request.
Has anyone been able to get CloudWatch logs out of `test-type` run in AWS? (non-local)
Contributor guide
Research direction
Start by inspecting cfn/logging/cloudwatchlogs.go at line 38 and the non-local test-type execution path described in the issue. Reproduce the regional difference, then check whether the execution environment and cfn test Event include the credential and log values. Done means identifying the cause of missing CloudWatch logs and documenting or implementing a confirmed resolution.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, go
- Domain
- cloud, devtools, testing
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100