diff --git a/localstack/README.md b/localstack/README.md new file mode 100644 index 0000000..d6d01e4 --- /dev/null +++ b/localstack/README.md @@ -0,0 +1,34 @@ +# Setup aws localstack + +1. Start docker + +``` +$ docker-composer up -d +``` + +2. to enter CLI + +``` +// check image name +$ docker ps + +// enter interactive bash shell +$ docker exec -it mongo-5-mongo-1 bash + +// enter to mongo shell +$ docker exec -it mongo-5-mongo-1 mongosh "mongodb://root@localhost:27017" +``` + +3. To test server. Using aws-cli to connect `localhost:27017`. login : `root` password : `example` + +4. Stop server +``` +$ docker-compose down +``` + + + +Ports + +* 4566-4599 : services +* 9000 : WEB ui \ No newline at end of file diff --git a/localstack/docker-compose.yml b/localstack/docker-compose.yml new file mode 100644 index 0000000..2f1c780 --- /dev/null +++ b/localstack/docker-compose.yml @@ -0,0 +1,17 @@ +version: "2.1" + +services: + localstack: + image: localstack/localstack + container_name: localstack + ports: + - "4566-4599:4566-4599" # ports of the different services + - "9000:9000" + environment: + - SERVICES=sqs,dynamodb # a list of desired services you want to use. + - DEFAULT_REGION=eu-west-1 # This is the region where your localstack mocks to be running + - DATA_DIR=/tmp/localstack/data + - PORT_WEB_UI=9000 + - LAMBDA_EXECUTOR=local + - DOCKER_HOST=unix:///var/run/docker.sock + - START_WEB=1