Overview
This explains how exe.dev solves a fundamental SSH limitation where multiple VMs can’t share IP addresses like web servers share domains. The key insight is that SSH lacks HTTP’s Host header mechanism, so they use a clever workaround involving IP allocation and SSH key identification.
The Breakdown
- SSH protocol limitation - Unlike HTTP which uses Host headers to route multiple domains to the same IP, SSH has no equivalent mechanism for distinguishing between different servers on shared infrastructure
- IP address allocation strategy - exe.dev assigns each VM a unique IP address within each user’s account, but these IPs are shared across different users’ accounts to conserve address space
- SSH key-based routing - The load balancer identifies users by their SSH public keys and uses this authentication data to route traffic to the correct underlying VM
- Domain-to-VM mapping - Users can SSH directly to named VMs (like simon.exe.dev) because the DNS resolves to account-specific IPs that the infrastructure can properly route