My D&D group needed a virtual tabletop. I could have paid for a hosted service and been done with it in five minutes. Instead I spent a weekend setting up Foundry VTT on a Raspberry Pi sitting in my living room. It works better than it has any right to.

// what it is

Foundry VTT is a self-hosted virtual tabletop application — dynamic maps, fog of war, dice rolling, and all the bells and whistles, running entirely on hardware you control. The Raspberry Pi is a credit-card-sized computer that costs around $80 and sips power like it's on a diet.

Together, they make a surprisingly capable D&D server that runs 24/7 for pennies a month in electricity. The whole setup is built on two main tools: felddy/foundryvtt-docker for a clean containerized Foundry install, and Cloudflare Tunnel to expose it securely to the internet — no port forwarding, no Nginx, no certificates to manage.

I followed Helping Ninja's playlist for most of the setup, skipping their Nginx/Certbot video in favour of Cloudflare Tunnel.

// how it works

1 — Static IP

First, give the Pi a fixed address on your local network so it doesn't change every time it reboots. Edit /etc/dhcpcd.conf and set your interface (wlan0 for WiFi, eth0 for ethernet), the IP you want, your gateway, and DNS servers. Reboot and verify with hostname -I.

2 — Firewall

Install UFW and open the ports you need:

sudo ufw allow 30000   # Foundry VTT
sudo ufw allow samba   # Samba share (optional)
sudo ufw reload

3 — Docker

Install Docker using the official script, then add your user to the docker group so you don't need sudo every time:

curl -sSL https://get.docker.com | sh
sudo usermod -aG docker ${USER}
sudo systemctl enable docker

Log out and back in to apply the group change, then verify with docker run hello-world.

4 — Samba share (optional but handy)

Create a shared folder so you can drag assets and modules onto the Pi from any computer on your network without SSH:

sudo mkdir -m 1777 ~/share
sudo apt install samba samba-common-bin
sudo smbpasswd -a pi

Add the share config to /etc/samba/smb.conf, then restart: sudo service smbd restart.

5 — Foundry VTT via Docker Compose

Create ~/docker/docker-compose.yml using the felddy/foundryvtt-docker image. The key bits: set network_mode: host, bind your Samba share as the data volume, and pass your Foundry account credentials as environment variables so the container can download Foundry automatically on first run.

mkdir ~/share/foundrydata
mkdir ~/docker
# create docker-compose.yml here
cd ~/docker && docker-compose up -d

Once running, Foundry is accessible at http://[pi-ip]:30000 on your local network.

6 — Cloudflare Tunnel

Instead of Nginx + Certbot, I used a Cloudflare Tunnel to expose the server publicly. The tunnel creates a secure outbound connection from the Pi to Cloudflare — no open ports on my router, no SSL certificates to renew, no reverse proxy to configure. Cloudflare handles HTTPS termination on their end.

Install cloudflared on the Pi, authenticate it to your Cloudflare account, then create a tunnel pointing to localhost:30000. In the Cloudflare dashboard, add a DNS CNAME record for your subdomain pointing to the tunnel. Done — dnd.archwyllt.ca now reaches Foundry over HTTPS.

// what I learned

The Helping Ninja series is genuinely beginner-friendly — each video is short and focused. The only detour I took was skipping Nginx entirely. The Cloudflare Tunnel approach is simpler and more robust: no certificates to expire, no web server to misconfigure, and the Pi never needs an open port. If you're already using Cloudflare for DNS (which you probably are), it's the obvious path.

Docker was the right call. Running Foundry bare-metal means manually managing updates, file permissions, and startup scripts. With the felddy image, updating Foundry is just pulling a new image. The Samba share turned out to be genuinely useful too — dragging module zips from my PC directly into the Pi's shared folder is much nicer than SCP.

// result

The server has been running without issue. My group plays regularly and it has never gone down mid-session. The Pi handles it without breaking a sweat, and my players don't know it's running off a computer the size of a deck of cards sitting in my living room.

You can reach the server at dnd.archwyllt.ca — though you'll need an invite to get in.

Mon groupe de D&D avait besoin d'un tabletop virtuel. J'aurais pu payer pour un service hébergé et en finir en cinq minutes. À la place, j'ai passé une fin de semaine à installer Foundry VTT sur un Raspberry Pi dans mon salon. Ça marche mieux que ça devrait.

// ce que c'est

Foundry VTT est une application de tabletop virtuel auto-hébergée — cartes dynamiques, brouillard de guerre, lancer de dés, et tout le reste, tournant entièrement sur du matériel que tu contrôles. Le Raspberry Pi est un ordinateur de la taille d'une carte de crédit qui coûte environ 80 $ et consomme très peu d'électricité.

Ensemble, ils forment un serveur D&D étonnamment capable qui tourne 24h/24 pour quelques sous par mois en électricité. L'installation repose sur deux outils principaux : felddy/foundryvtt-docker pour une installation Foundry propre dans un conteneur, et Cloudflare Tunnel pour l'exposer de façon sécurisée sur internet — pas de redirection de ports, pas de Nginx, pas de certificats à gérer.

J'ai suivi la playlist de Helping Ninja pour la majeure partie de l'installation, en sautant leur vidéo Nginx/Certbot au profit de Cloudflare Tunnel.

// comment ça fonctionne

1 — IP statique

D'abord, donner au Pi une adresse fixe sur le réseau local pour qu'elle ne change pas à chaque redémarrage. Modifier /etc/dhcpcd.conf et définir l'interface (wlan0 pour le WiFi, eth0 pour l'ethernet), l'IP souhaitée, la passerelle et les serveurs DNS. Redémarrer et vérifier avec hostname -I.

2 — Pare-feu

Installer UFW et ouvrir les ports nécessaires :

sudo ufw allow 30000   # Foundry VTT
sudo ufw allow samba   # Partage Samba (optionnel)
sudo ufw reload

3 — Docker

Installer Docker avec le script officiel, puis ajouter l'utilisateur au groupe docker pour ne pas avoir à taper sudo à chaque fois :

curl -sSL https://get.docker.com | sh
sudo usermod -aG docker ${USER}
sudo systemctl enable docker

Se déconnecter et se reconnecter pour appliquer le changement de groupe, puis vérifier avec docker run hello-world.

4 — Partage Samba (optionnel mais pratique)

Créer un dossier partagé pour pouvoir glisser des ressources et des modules sur le Pi depuis n'importe quel ordinateur du réseau sans passer par SSH :

sudo mkdir -m 1777 ~/share
sudo apt install samba samba-common-bin
sudo smbpasswd -a pi

Ajouter la configuration du partage dans /etc/samba/smb.conf, puis redémarrer : sudo service smbd restart.

5 — Foundry VTT via Docker Compose

Créer ~/docker/docker-compose.yml avec l'image felddy/foundryvtt-docker. Les points clés : définir network_mode: host, lier le partage Samba comme volume de données, et passer les identifiants du compte Foundry comme variables d'environnement pour que le conteneur télécharge Foundry automatiquement au premier démarrage.

mkdir ~/share/foundrydata
mkdir ~/docker
# créer docker-compose.yml ici
cd ~/docker && docker-compose up -d

Une fois lancé, Foundry est accessible à http://[ip-du-pi]:30000 sur le réseau local.

6 — Cloudflare Tunnel

Plutôt que Nginx + Certbot, j'ai utilisé un Cloudflare Tunnel pour exposer le serveur publiquement. Le tunnel crée une connexion sortante sécurisée du Pi vers Cloudflare — pas de ports ouverts sur le routeur, pas de certificats SSL à renouveler, pas de reverse proxy à configurer. Cloudflare gère la terminaison HTTPS de son côté.

Installer cloudflared sur le Pi, l'authentifier auprès du compte Cloudflare, puis créer un tunnel pointant vers localhost:30000. Dans le tableau de bord Cloudflare, ajouter un enregistrement DNS CNAME pour le sous-domaine pointant vers le tunnel. Et voilà — dnd.archwyllt.ca rejoint Foundry en HTTPS.

// ce que j'ai appris

La série de Helping Ninja est vraiment accessible aux débutants — chaque vidéo est courte et ciblée. Le seul détour que j'ai pris, c'est de sauter complètement Nginx. L'approche Cloudflare Tunnel est plus simple et plus robuste : pas de certificats qui expirent, pas de serveur web à mal configurer, et le Pi n'a jamais besoin d'un port ouvert. Si tu utilises déjà Cloudflare pour le DNS (ce qui est probablement le cas), c'est la voie évidente.

Docker était le bon choix. Faire tourner Foundry directement sur le système signifie gérer manuellement les mises à jour, les permissions de fichiers et les scripts de démarrage. Avec l'image felddy, mettre à jour Foundry se résume à récupérer une nouvelle image. Le partage Samba s'est aussi révélé vraiment utile — glisser des zips de modules depuis mon PC directement dans le dossier partagé du Pi, c'est bien plus agréable que SCP.

// résultat

Le serveur tourne sans problème. Mon groupe joue régulièrement et ça n'a jamais planté en pleine session. Le Pi s'en sort sans broncher, et mes joueurs ne savent pas qu'on joue sur un ordinateur de la taille d'un paquet de cartes posé dans mon salon.

Vous pouvez accéder au serveur à dnd.archwyllt.ca — mais il faut une invitation pour entrer.