AWS Lambda function that reads data (.csv file) from a configured S3 bucket and stores into Dynamodb table. Infrastructure provisioning is setup using AWS CDK.
- npm
- aws cli
- aws cdk
- sam cli (Optional)
- Docker Desktop
-
Install dependencies from root directory from the location of
package.json
npm i
-
Change current directory to
file-processor-infra
.Build the project using AWS CDK CLI. This will create the AWS cloud formation template infile-processor-infra/cdk.out
foldercdk synth
-
Deploy the stack using AWS CDK.
cdk deploy
-
Once the above command is successful, copy the test
.csv
file to the bucket by running below command. Thetestdata.csv
is located atfile-processor-app/test/testdata.csv
aws s3 cp testdata.csv s3://csv-input-data-bucket/testdata.csv