Skip to main content

On VM Deployment Architecture (Azure)

This page describes the infrastructure and application architecture of CodeMie On VM on Azure.

Infrastructure Overview

Azure On VM Infrastructure Architecture

CodeMie On VM runs on a single Azure VM with supporting Azure services. Terraform provisions the following resources:

ResourcePurpose
Azure VM (Standard_E4s_v5)Single VM running Docker Compose (4 vCPU, 32 GB RAM)
Virtual Network / SubnetIsolated network for the VM
Network Security GroupControls inbound/outbound traffic to the VM
Azure Storage AccountPersistent storage for user data (repos, files)
Azure Key VaultEncryption key management for storage data
Private DNS ZoneCustom domain resolution (when TF_VAR_platform_domain_name is set)
Azure BastionSecure SSH access to the VM without exposing a public IP

Network Modes

ModeConfigurationAccess
Private IP (default)TF_VAR_platform_domain_name emptyVM private IP, access via VPN or Bastion
DomainTF_VAR_platform_domain_name="private.lab.com"Creates private DNS zone, access via name

Application Architecture

All CodeMie services run as Docker containers on the Azure VM, orchestrated by Docker Compose.

Docker Compose Services

Services by Profile

Shared services (both profiles):

ServiceImagePurpose
postgrespgvector/pgvector:pg17Primary database for application data
elasticsearchelasticsearch:8.xDocument storage and search for Data Sources
kibanakibana:8.xLog visualization and analytics for Elasticsearch
mcp-connectcodemie-mcp-connect-serviceConnector for MCP servers
nginxnginx:1.31-alpineReverse proxy, TLS termination

OSS profile:

ServicePurpose
codemie-ossAPI server with built-in local authentication
codemie-ui-ossWeb frontend

Enterprise profile:

ServicePurpose
codemieAPI server
codemie-uiWeb frontend
keycloakIdentity provider (SSO, OIDC)
oauth2-proxyAuthentication proxy in front of nginx
litellmLLM proxy for model routing and key management
natsMessaging for plugin engine
nats-auth-calloutNATS authentication service
mermaid-serverDiagram rendering

Resource Requirements

Minimum Azure VM

ResourceMinimumRecommended
vCPU44 (Standard_E4s_v5)
RAM16 GB32 GB
Disk50 GB100 GB

Next Steps

  • Deployment — Deploy CodeMie On VM with Terraform