Back to Guides

Deploy AnythingMCP on Microsoft Azure

Deploy AnythingMCP on an Azure Virtual Machine with Docker Compose and automatic HTTPS. Enterprise-ready MCP gateway on Azure.

Prerequisites

  • An Azure account with permission to create VMs
  • A domain name with DNS access

Create a Virtual Machine

In the Azure Portal:

  1. Click Create a resource > Virtual Machine
  2. Image: Ubuntu 24.04 LTS
  3. Size: B2s (2 vCPU, 4 GB) or B2ms for heavier workloads
  4. Authentication: SSH public key
  5. Inbound ports: allow SSH (22)

After creation, assign a static public IP to the VM.

Install Docker

ssh azureuser@VM_PUBLIC_IP
curl -fsSL https://get.docker.com | sh
sudo usermod -aG docker $USER
newgrp docker

Configure DNS

Create an A record (Azure DNS or external provider):

| Record | Type | Value | |--------|------|-------| | mcp.example.com | A | VM_PUBLIC_IP |

Network Security Group

In the Azure Portal, go to your VM's Networking tab and add inbound rules:

| Port | Protocol | Priority | Description | |------|----------|----------|-------------| | 80 | TCP | 100 | HTTP (Caddy redirect) | | 443 | TCP | 110 | HTTPS |

SSH (port 22) should already be allowed from creation.

Deploy AnythingMCP

git clone https://github.com/HelpCode-ai/anythingmcp.git
cd anythingmcp
bash setup.sh

Enter your domain when prompted. The script configures Caddy for automatic SSL and starts all services.

Verify & Next Steps

Open https://mcp.example.com. Register your admin account — the first user becomes administrator.

Your MCP endpoint: https://mcp.example.com/mcp

# Update to latest version
git pull && docker compose up -d --build