Skip to main content

Local-first Azure emulator — build, test, and iterate without an Azure account.

Project description

Amber

Amber logo

Local-first Azure emulator — Build, test, and iterate on Azure services without an Azure account.

PyPI version Python versions CI Docs License

Amber emulates 86 Azure service-family surfaces across 17 categories, all running locally with zero core runtime dependencies. Every operation records billing usage so you can estimate costs before deploying to real Azure.

Amber is a developer test double, not Microsoft Azure. It provides useful local behavior, ARM-shaped resource IDs, region and zone metadata, billing ledgers, and adapter hooks while documenting where cloud validation is still required.

Amber is inspired by the local-cloud developer experience pioneered by Floci for AWS, and brings that same kind of fast local workflow to Azure-shaped Python, CLI, and REST development.

Quick Start

from amber import AmberWorkspace

ws = AmberWorkspace.create(".amber")

# Blob Storage
ws.storage.blob.create_container("data")
ws.storage.blob.put_blob("data", "hello.txt", b"Hello, Azure!")

# Redis Cache
ws.redis.set(0, "session:1", "active")
assert ws.redis.get(0, "session:1") == "active"

# Cosmos DB
ws.cosmosdb.create_account("myaccount")
ws.cosmosdb.create_database("myaccount", "mydb")
ws.cosmosdb.create_container("myaccount", "mydb", "items", "/category")
ws.cosmosdb.create_document("myaccount", "mydb", "items", {
    "id": "doc1", "category": "fruit", "name": "apple"
})

# Service Bus messaging
ws.servicebus.create_queue("orders")
ws.servicebus.send_to_queue("orders", "new-order-123")

# Check billing
for key, usage in sorted(ws.billing.summary().items()):
    print(f"{key}: {usage.quantity} {usage.unit}")

ws.close()

Installation

pip install amber-cloud

Amber is published on PyPI as amber-cloud, while the import package and CLI are both amber.

Documentation

Local Azure Workflows

amber doctor
amber az group create --name apps --location eastus --tags env=dev
amber az group list
eval "$(amber env --endpoint http://127.0.0.1:8000)"

For an optional ARM-shaped local endpoint:

pip install "amber-cloud[server]"
python -m amber.server --workspace .amber --host 127.0.0.1 --port 8000

Why Amber

  • Run Azure-shaped integration tests locally without cloud accounts or shared test subscriptions.
  • Keep application code close to ARM-shaped IDs, locations, tags, resource groups, and service-family names.
  • Prototype lift-and-shift flows before replacing local adapters with real Azure SDK clients or deployment pipelines.
  • Give students, teams, and open-source projects a fast local playground for Azure concepts.

Service Coverage (86 services)

Category Services
Storage Blob, Queue, Table, Files, Data Lake Gen2
Databases Redis, Cosmos DB, Azure SQL, PostgreSQL, MySQL, Database Migration Service
Messaging Service Bus, Event Hubs, Event Grid
Compute Functions, App Service, Container Apps, Batch, Static Web Apps, Virtual Machines, Managed Disks, VM Scale Sets, Service Fabric, Azure Virtual Desktop
Containers ACR, AKS
Networking VNet, Load Balancer, DNS, Firewall, App Gateway, Front Door, CDN, Traffic Manager, NAT Gateway, Private DNS, Bastion, Private Link, ExpressRoute, VPN Gateway, WAF
AI Azure OpenAI, Azure AI services, AI Search, Maps, Document Intelligence/Form Recognizer, Speech, Content Safety/Content Moderator compatibility
Analytics Data Factory, Kusto (Data Explorer), Stream Analytics, Purview, Synapse Analytics, Machine Learning
Governance Policy, RBAC, Cost Management, Advisor, Resource Graph
Observability Azure Monitor, Application Insights
Identity Managed Identity / Service Principals
Security Key Vault, Managed HSM, Confidential Ledger, DDoS Protection
Integration Logic Apps, API Management, IoT Hub, SignalR, Communication Services, Notification Hubs, Web PubSub, Digital Twins
DevOps Azure DevOps (projects, pipelines)
Automation Azure Automation (runbooks, jobs, variables)
Media Azure Media Services-style legacy workflows (retired in Azure; local compatibility only)
Management Billing, Resource Groups, Subscriptions, Locks, Tags, Activity Log, Blueprints legacy workflows, Maintenance, Change Analysis

Public Python API

Amber is packaged as amber-cloud and imported as amber:

from amber import AmberWorkspace
from amber.core import ServiceRegistry
from amber.cosmosdb import CosmosDBService
from amber.storage import BlobStorageService, QueueStorageService
from amber.networking import VNetService

The subpackages intentionally mirror Azure service families so tests and prototypes can move from local Amber code toward Azure SDK or deployment workflows with minimal conceptual translation. See the Sphinx documentation's Microsoft References page for the official Microsoft docs that each local service surface maps to.

Architecture

  • SQLite persistence with WAL mode for concurrent access
  • Content-addressed blob storage with SHA-256 deduplication
  • Lazy service initialization — only loaded when accessed
  • Thread-safe workspace with double-checked locking
  • Zero external dependencies — pure Python stdlib

Commands

Command Description
pip install -e '.[dev]' Install for local development
.venv/bin/python -m pytest Run the Python test suite
.venv/bin/ruff check src tests Run Python lint checks
.venv/bin/mypy src Run the configured type checks
.venv/bin/python -m build Build sdist and wheel
amber registry list List all registered services
amber doctor Check local package, workspace, SQLite, registry, and optional server deps
amber status Show workspace, registered services, resource groups, and resources
amber env --format json Emit local endpoint and Azure-shaped environment metadata
amber az account show Show the local subscription document
amber az group create --name apps --location eastus Create an ARM-shaped local resource group
amber compose Print a Docker Compose service for the optional REST server
amber billing summary Show local billing summary

Go Core

The Go runtime and CLI remain alongside the Python package:

go test ./...
go run ./cmd/amber --workspace .amber doctor
go run ./cmd/amber --workspace .amber status

License

Apache 2.0. Azure, Microsoft Azure, and related service names are trademarks of Microsoft Corporation. Amber is independent and is not affiliated with, endorsed by, or sponsored by Microsoft Corporation.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

amber_cloud-1.0.0.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

amber_cloud-1.0.0-py3-none-any.whl (198.3 kB view details)

Uploaded Python 3

File details

Details for the file amber_cloud-1.0.0.tar.gz.

File metadata

  • Download URL: amber_cloud-1.0.0.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for amber_cloud-1.0.0.tar.gz
Algorithm Hash digest
SHA256 edbbffb8885d1c8ea9f1e1a9dd53d194910a974051b4562beb647bb640ce843c
MD5 98e5b714d570a0f8feeda3223364d5df
BLAKE2b-256 28cff77e35d27899c9f138681e8b7723867cd9c4c39e7c048cea8ef305b13c5e

See more details on using hashes here.

Provenance

The following attestation bundles were made for amber_cloud-1.0.0.tar.gz:

Publisher: publish.yml on Vishwa-docs/amber

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file amber_cloud-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: amber_cloud-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 198.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for amber_cloud-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9bc12bb1f5d77deb217ce195f2161d54e123f2d8080710660a2aada2416cc567
MD5 66cc251db7f780c595ba66fa6d2ba97f
BLAKE2b-256 0fd90a60ac1ea621c0831a7ac3e1016adc14fb1ba43d992101bcc83f176d731e

See more details on using hashes here.

Provenance

The following attestation bundles were made for amber_cloud-1.0.0-py3-none-any.whl:

Publisher: publish.yml on Vishwa-docs/amber

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page