File tree Expand file tree Collapse file tree 3 files changed +19
-6
lines changed
Expand file tree Collapse file tree 3 files changed +19
-6
lines changed Original file line number Diff line number Diff line change 1- version : " 3"
21services :
32 dynamodb :
4- image : amazon/dynamodb-local:2.0.0
3+ image : amazon/dynamodb-local:2.6.1
54 container_name : app-dynamodb
65 hostname : app-dynamodb
76 volumes :
@@ -11,12 +10,18 @@ services:
1110 - " 8000:8000"
1211 command : " -jar DynamoDBLocal.jar -sharedDb -dbPath ."
1312 restart : unless-stopped
13+ networks :
14+ - db-network
1415
1516 dynamodb_migrator :
16- image : amazon/aws-cli:2.13.6
17+ image : amazon/aws-cli:2.31.28
1718 container_name : app-dynamodb_migrator
1819 working_dir : /home/dynamodblocal
19- command : dynamodb create-table --cli-input-json file://paste.json --endpoint-url http://dynamodb:8000
20+ entrypoint : ["/bin/sh", "-c"]
21+ command :
22+ - |
23+ sleep 5
24+ aws dynamodb create-table --cli-input-json file://paste.json --endpoint-url http://app-dynamodb:8000
2025 volumes :
2126 - ./schema:/home/dynamodblocal
2227 environment :
@@ -25,7 +30,15 @@ services:
2530 - AWS_DEFAULT_REGION=local
2631 depends_on :
2732 - dynamodb
33+ restart : on-failure
34+ networks :
35+ - db-network
2836
2937volumes :
3038 app_dynamodb :
3139 driver : local
40+
41+ networks :
42+ db-network :
43+ driver : bridge
44+
Original file line number Diff line number Diff line change 11{
22 "queryStringParameters" : {
3- "id" : " f679e04f75bb74285359000765ea2af86adb198a "
3+ "id" : " 10a04c0b8c91a4bd996efa6b22beda1aab08f210 "
44 },
55 "httpMethod" : " GET" ,
66 "path" : " /" ,
Original file line number Diff line number Diff line change 11{
2- "content" : " examplary job " ,
2+ "content" : " focuse on efficiency " ,
33 "httpMethod" : " POST" ,
44 "path" : " /" ,
55 "requestContext" : {
You can’t perform that action at this time.
0 commit comments