Local Stack - Getting Started
January 1, 2025Less than 1 minute
Install LocalStack
Step 1: Getting the
LocalStack
docker Imagedocker pull localstack/localstack
Step 2: Install AWSLocal
pip install awscli-local
Step 3: Install LocalStack CLI
curl --output localstack-cli-4.0.0-linux-amd64-onefile.tar.gz \
--location https://github.com/localstack/localstack-cli/releases/download/v4.0.0/localstack-cli-4.0.0-linux-amd64-onefile.tar.gz
tar -xvf localstack-cli-4.0.0-linux-amd64-onefile.tar.gz
- Step 4: Start LocalStack
localstack start
Create Resources
- create s3 bucket
awslocal s3 mb s3://test-bucket
Configure AWS endpoint to LocalStack
The following example point the default profile to LocalStack.
[default]
aws_access_key_id = test
aws_secret_access_key = test
region = us-east-1
output = json
endpoint_url = http://localhost:4566
After the configuration, can using aws-cli to operate LocalStack resources.
Reference
LocalStack 101: Getting started
LocalStack - Docs - Getting Started