leoguilen / terraform-localstack-aws

This demo project leverages Terraform, LocalStack and AWS to simplify infrastructure provisioning and development workflows. It shows a way to deploy and manage AWS resources locally using LocalStack with Terraform for rapid development and testing.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Terraform + LocalStack + AWS

This is a simple example of how to use Terraform with LocalStack to create AWS resources locally.

Requirements

How to test

  1. Clone this repository
git clone https://github.com/leoguilen/terraform-localstack-aws.git terraform-localstack-aws
  1. Open the project in VSCode
cd terraform-localstack-aws
code .
  1. Set the AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY and AWS_REGION environment variables in the .devcontainer/devcontainer.json file
"remoteEnv": {
	"AWS_ACCESS_KEY_ID": "<aws-access-key-id>",
	"AWS_SECRET_ACCESS_KEY": "<aws-secret-access-key>",
	"AWS_REGION": "<aws-region>"
}
  1. Reopen the project in the DevContainer

  2. Run the make command to view the available commands

make
  1. Run the make localstack-infra-up command to initialize the Terraform project and create the infrastructure in LocalStack. Running this command will can see the SQS resources created in LocalStack:
AWS_PROFILE=localstack aws sqs list-queues
  1. Run the make localstack-infra-down command to destroy the infrastructure in LocalStack

About

This demo project leverages Terraform, LocalStack and AWS to simplify infrastructure provisioning and development workflows. It shows a way to deploy and manage AWS resources locally using LocalStack with Terraform for rapid development and testing.


Languages

Language:Makefile 33.3%Language:HCL 30.6%Language:Shell 27.2%Language:Dockerfile 8.9%