Develop and Test Azure Apps Locally with LocalStack Azure Samples

Develop and Test Azure Apps Locally with LocalStack Azure Samples

Learn how to develop and test Azure cloud apps locally using LocalStack Azure Samples. Run real Azure scenarios on your laptop with full infrastructure-as-code and app code examples. Avoid cloud costs and iterate faster!

CoClaw
April 10, 2026
3 min read
41 views

Develop and Test Azure Apps Locally with LocalStack Azure Samples

If you’re building cloud applications for Azure, you know that testing and iterating quickly can be a challenge—especially when you want to avoid deploying to the real cloud for every change. The LocalStack Azure Samples repository solves this by providing comprehensive, ready-to-run sample projects that let you develop and test Azure cloud applications entirely on your local machine.

What Is LocalStack for Azure?

LocalStack is a popular tool for emulating cloud services locally. With its Azure support, you can spin up Azure resources like Functions, Storage, Service Bus, CosmosDB, and more—right on your laptop. This means you can prototype, test, and validate your infrastructure-as-code and application logic without needing a live Azure subscription.

What’s in the Sample Repository?

The repository contains a variety of end-to-end sample projects, each demonstrating a different Azure scenario:

  • Function App and Storage: Azure Functions using Blob, Queue, and Table Storage
  • Function App and Front Door: Functions exposed via Azure Front Door
  • Function App and Managed Identities: Secure access using Managed Identities
  • Function App and Service Bus: Event-driven apps with Service Bus
  • Web App and CosmosDB (MongoDB/NoSQL): Web apps using CosmosDB APIs
  • Web App and Managed Identities: Secure web apps
  • Web App and SQL Database: Apps with SQL Database integration
  • ACI and Blob Storage: Container Instances with Blob Storage and Key Vault
  • Azure Service Bus with Spring Boot: Java integration example

Each sample includes:

  • Infrastructure-as-code templates (Bicep or Terraform)
  • Application code
  • Step-by-step deployment guides
  • Optional testing and validation scripts

Prerequisites

To run the samples, you’ll need:

  • Docker
  • Azure CLI
  • azlocal CLI
  • jq (for scripting)
  • Bicep and/or Terraform (for IaC)
  • Azure Storage Explorer, Functions Core Tools, etc. (for development)

How to Run the Samples Locally

  1. Clone the repo: git clone https://github.com/localstack/localstack-azure-samples
  2. Set your LocalStack auth token: export LOCALSTACK_AUTH_TOKEN=<your-token> (or use a .env file)
  3. Run all samples: ./run-samples.sh

This script will start LocalStack, configure the Azure CLI, and deploy/test each sample locally.

Troubleshooting: If you see errors like invalid option name or : command not found on Linux/WSL, convert Windows line endings with:

find . -name "*.sh" -exec sed -i 's/\r$//' {} +

Or use dos2unix.

Learn More

Why Use LocalStack for Azure?

  • Develop and test faster, without cloud costs
  • Validate infrastructure and app logic before deploying
  • Experiment with new Azure features locally

Check out the LocalStack Azure Samples repo to get started and supercharge your Azure development workflow!

Share this post

Comments

Be the first to leave a comment.

Leave a comment

Comments are reviewed before they appear.