Deploying on Azure
On this page
- Architecture
- Prerequisites
- VM Size Selection
- Storage Configuration
- Managed Disk Types
- Disk Configuration
- /etc/fstab Configuration
- Networking
- Network Security Groups
- Proximity Placement Groups
- Encryption
- At-Rest Encryption with Azure Key Vault
- In-Transit Encryption with TLS
- Identity and Access Management
- Deployment with Terraform
- Monitoring Integration
- Azure Monitor
- Backup Strategy
- Azure Backup
- Disk Snapshots
- Cost Optimization
- Related Documentation
Deploy Kimberlite on Microsoft Azure.
Architecture
┌─────────────────────────────────────────────────────────┐
│ Virtual Network (VNet) │
│ ┌──────────────┐ ┌────────────────┐ ┌──────────────┐│
│ │ Zone 1 │ │ Zone 2 │ │ Zone 3 ││
│ │ │ │ │ │ ││
│ │ ┌────────┐ │ │ ┌──────────┐ │ │ ┌────────┐ ││
│ │ │ Node 1 │ │ │ │ Node 2 │ │ │ │ Node 3 │ ││
│ │ │(Leader)│ │ │ │ │ │ │ │ │ ││
│ │ └────────┘ │ │ └──────────┘ │ │ └────────┘ ││
│ └──────────────┘ └────────────────┘ └──────────────┘│
└─────────────────────────────────────────────────────────┘
Prerequisites
- Azure subscription with Virtual Machines permissions
- Azure CLI installed and authenticated
- Terraform or ARM templates (optional)
VM Size Selection
Recommended VM Sizes:
| Workload | VM Size | vCPUs | Memory | Network | Disk |
|---|---|---|---|---|---|
| Small | Standard_D2s_v5 | 2 | 8 GB | 12.5 Gbps | 100 GB Premium SSD |
| Medium | Standard_D4s_v5 | 4 | 16 GB | 12.5 Gbps | 500 GB Premium SSD |
| Large | Standard_D8s_v5 | 8 | 32 GB | 12.5 Gbps | 1 TB Premium SSD |
| Production | Standard_D16s_v5 | 16 | 64 GB | 12.5 Gbps | 2 TB Premium SSD |
VM Selection Tips:
- Use
Dsv5series for balanced workloads - Use
Fsv2series for compute-intensive workloads - Use
Esv5series for memory-intensive workloads - Use availability zones for high availability
Storage Configuration
Managed Disk Types
| Disk Type | IOPS | Throughput | Use Case | Cost |
|---|---|---|---|---|
| Premium SSD | 120-20,000 | 25-900 MB/s | Recommended for log | $0.135/GB-month |
| Standard SSD | 500-6,000 | 60-750 MB/s | Cost-optimized | $0.075/GB-month |
| Ultra Disk | 300-160,000 | 2,000 MB/s | Ultra-high performance | $0.12/GB-month + IOPS cost |
| Standard HDD | 500-2,000 | 60-500 MB/s | NOT for log | $0.045/GB-month |
Recommendations:
- Log disk: Premium SSD P30 (1 TB, 5000 IOPS)
- Projection disk: Standard SSD E20 (512 GB, 500 IOPS)
- Use separate disks for log and projections
Disk Configuration
# Create resource group
# Create managed disks
# Create VM with attached disks
# Format and mount (SSH into VM)
/etc/fstab Configuration
# Find disk UUIDs
# Add to /etc/fstab
UUID=xxx
UUID=yyy
Networking
Network Security Groups
# Create VNet
# Create NSG
# Client traffic (from application subnet)
# Cluster traffic (between nodes)
# Metrics (from monitoring subnet)
# SSH (from bastion only)
Proximity Placement Groups
For lowest latency between nodes:
Encryption
At-Rest Encryption with Azure Key Vault
# /etc/kimberlite/config.toml
[encryption]
enabled = true
kms_provider = "azure-keyvault"
kms_key_id = "https://kimberlite-kv.vault.azure.net/keys/data-key/version"
Create Key Vault and key:
# Create Key Vault
# Create encryption key
# Grant VM managed identity access
VM_IDENTITY=
In-Transit Encryption with TLS
Use Azure certificates or self-signed:
# Using App Service Certificate
# Or use Let's Encrypt
Identity and Access Management
Managed Identity Configuration:
# Enable system-assigned identity
# Grant permissions
Deployment with Terraform
# main.tf
resource "azurerm_linux_virtual_machine" "kimberlite_node" {
count = 3
name = "kimberlite-node-${count.index + 1}"
resource_group_name = azurerm_resource_group.main.name
location = azurerm_resource_group.main.location
size = "Standard_D4s_v5"
zone = count.index + 1
network_interface_ids = [
azurerm_network_interface.main[count.index].id,
]
os_disk {
caching = "ReadWrite"
storage_account_type = "Premium_LRS"
}
source_image_reference {
publisher = "Canonical"
offer = "0001-com-ubuntu-server-jammy"
sku = "22_04-lts-gen2"
version = "latest"
}
identity {
type = "SystemAssigned"
}
custom_data = base64encode(templatefile("cloud-init.yaml", {
node_id = count.index + 1
}))
}
resource "azurerm_managed_disk" "log" {
count = 3
name = "kimberlite-log-${count.index + 1}"
location = azurerm_resource_group.main.location
resource_group_name = azurerm_resource_group.main.name
storage_account_type = "Premium_LRS"
create_option = "Empty"
disk_size_gb = 1024
zone = count.index + 1
}
resource "azurerm_virtual_machine_data_disk_attachment" "log" {
count = 3
managed_disk_id = azurerm_managed_disk.log[count.index].id
virtual_machine_id = azurerm_linux_virtual_machine.kimberlite_node[count.index].id
lun = 0
caching = "None"
}
Monitoring Integration
Azure Monitor
Export Kimberlite metrics to Azure Monitor:
# Install Azure Monitor agent
# Configure data collection rule
dcr.json:
Backup Strategy
Azure Backup
# Create Recovery Services vault
# Enable backup for VMs
Disk Snapshots
# Create snapshot
# Schedule snapshots (use Logic Apps or Automation)
Cost Optimization
Estimated Monthly Costs (3-node cluster):
| Component | Configuration | Cost |
|---|---|---|
| 3x Standard_D4s_v5 | 24/7 | $380 |
| 3x Premium SSD 1 TB | P30 | $420 |
| 3x Standard SSD 512 GB | E20 | $75 |
| Data transfer | 1 TB/month | $87 |
| Total | ~$962/month |
Cost Reduction Tips:
- Use Azure Reserved Instances (up to 72% discount)
- Use Spot VMs for non-critical workloads (up to 90% discount)
- Use Standard SSD instead of Premium SSD where possible
- Delete old snapshots regularly
Related Documentation
- Deployment Guide - General deployment patterns
- Configuration Guide - Configuration options
- Security Guide - TLS setup
- Monitoring Guide - Observability
Key Takeaway: Use Premium SSD for log disk, deploy across availability zones, enable Key Vault encryption, and use Azure Monitor for observability.