Server Migration
Mini PC migration — WSL 2 + Docker Engine
When migrating from an M1 Mac to a Mini PC running Windows + WSL 2, the identical docker-compose.yml works without edits.
1. Enable WSL 2
powershell
# Run PowerShell as Administrator
wsl --install -d Ubuntu-24.04
# Reboot, then set your Linux username/password2. Configure WSL 2 memory
Create C:\Users\<you>\.wslconfig:
ini
[wsl2]
memory=12GB # adjust for your Mini PC RAM
swap=4GB
processors=4
localhostForwarding=truepowershell
wsl --shutdown # apply changes3. Install Docker Engine (not Docker Desktop)
bash
# Inside WSL 2 Ubuntu shell:
# Remove old packages
for pkg in docker.io docker-doc docker-compose podman-docker containerd runc; do
sudo apt-get remove -y $pkg 2>/dev/null
done
# Add Docker's official GPG key + repo
sudo apt-get update
sudo apt-get install -y ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] \
https://download.docker.com/linux/ubuntu $(. /etc/os-release && echo $VERSION_CODENAME) stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
# Install Docker Engine + Compose plugin
sudo apt-get update
sudo apt-get install -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
# Add your user to the docker group (no sudo needed for docker commands)
sudo usermod -aG docker $USER
newgrp docker
# Verify
docker --version # 27+
docker compose version # v2.30+4. Auto-start Docker on WSL boot
bash
# Docker starts automatically with systemd in WSL 2 (Ubuntu 24.04+)
sudo systemctl enable docker
# Verify it's running
sudo systemctl status docker5. Migrate your homelab
bash
# Clone the repo
git clone https://github.com/nichehemanth/h5h.git ~/h5h
cd ~/h5h/code
# Copy data/ from Mac (or external drive)
# Option A: rsync over Tailscale
rsync -avzP hemanth@<mac-tailscale-ip>:~/Desktop/hemanth/h5h/data/ ~/h5h/data/
# Option B: external drive (mounted at /mnt/d/ in WSL)
cp -r /mnt/d/h5h-backup/data/ ~/h5h/data/
# Setup and start
make init
make up # starts ALL 26 containersKey differences: OrbStack (Mac) vs WSL 2 (Mini PC)
| Feature | OrbStack (Mac) | WSL 2 (Mini PC) |
|---|---|---|
| Docker Engine | OrbStack VM | Native Linux kernel |
/proc, /sys | VM-level (limited) | Real host (full Node Exporter) |
| Kernel modules | Not available | Available (WireGuard native) |
| RAM sharing | Dynamic | Fixed .wslconfig limit |
| Performance | Good (VirtIO) | Near-native |
make up | Partial (8 GB limit) | Full stack (16+ GB) |
No changes to
docker-compose.ymlneeded. The same file runs on OrbStack today and WSL 2 tomorrow.