[terraform] Expose shared dynamodb tables
Summary:
This stack resolves issues encountered when setting up fresh staging AWS account with Terraform.
This diff resolves an issue when running terraform plan on plain fresh AWS account. The aws_dynamodb_table data doesn't resolve to anything because the DDB table isn't yet created.
Resources from inside module aren't globally exposed, so I created a outputs.tf file in the shared module and iterated over explicitly-specified table resources to expose them.
I really wanted to do it in a more automated way, but TF has no good mechanism for iterating over all resources yet. There's an open issue for that where people share other usecases for such feature.
Depends on D8714
Test Plan: Production terraform plan with no changes. Staging plan no longer fails.
Reviewers: jon, varun
Reviewed By: jon
Subscribers: ashoat, tomek
Differential Revision: https://phab.comm.dev/D8715