jdharanms / DockerAssignment

0 stars 0 forks source link

Missing docker compose service to run terraform and trigger the lambda + use the original one JSON #1

Open pontusvision opened 2 months ago

pontusvision commented 2 months ago

Hi Murali,

Thank you for your hard work; however, the final product does not fully match the original ask. Can you please create the missing docker compose service to run terraform and trigger the lambda? Here is the original ask for reference:

Create a Docker Compose file with the following services:
Localstack Service:
   Emulate AWS services like S3 and Lambda.
   Should expose necessary AWS service endpoints.
SQL Server Service:
  Run an instance of SQL Server.
  Ensure it has a database with a table having two columns: timestamp and data (JSON text).
  Make sure it is initialized properly with a database and table setup script.
Terraform Service:
  This container should have Terraform installed.
  It will run Terraform scripts to deploy the Lambda function and set up the infrastructure on Localstack.
  It should run tests to trigger the Lambda function.

Lastly, can you also please amend the code to use the original JSONL file (without the [] between the JSON objects, keeping one object per line JSONL format) ?

Thanks.

jdharanms commented 2 months ago

Hi Created a Docker compose file having three service 1)LocalStack service: containing S3 and lambda function 2) Terraform service: This will provision trigger function, create S3 bucket, and was lambda functions. 3) SQL service: As soon as the SQL container spins up, database and table will be created, but instead of creating two columns have created four columns (timestamp, id , name and value)