Skip to content
Back

Running Appwrite in docker through nginx

  • 0
  • Self Hosted
koussay Issaoui
3 Apr, 2026, 14:03

Hi team,

I'm trying to expose multiple local services (Appwrite, Ollama, PostHog) through a single Nginx reverse proxy port, tunneled via ngrok to a public domain — so that my mobile app can reach them at URLs like:

www.domain.com/appwrite/ www.domain.com/ollama/ www.domain.com/posthog/

The motivation is that mobile apps are strict about networking — querying localhost directly requires overriding the HTTP adapter, which I'd like to avoid.

My current setup:

  • Nginx runs in Docker and joins Appwrite's existing Traefik network
  • Nginx proxies /appwrite/ → appwrite-traefik:80
  • ngrok tunnels the single Nginx port to the public endpoint

The issue: When I hit /appwrite/, Traefik returns a 301 redirect to /console/, which Nginx doesn't handle — so it falls back to my default route and returns a JSON status message instead of the Appwrite UI.

I've attached my nginx.conf and docker-compose.yml below. Is there a detailed guide for this kind of path-based proxying in front of Traefik? Or is there a recommended way to wire Nginx into Appwrite's network without interfering with Traefik's routing?

Thanks!

TL;DR
- Developer needs to expose multiple services through a single Nginx reverse proxy port for mobile app accessibility. - Issue: Traefik returning 301 redirect to /console/ when hitting /appwrite/. - Developer provided nginx.conf and docker-compose.yml. - Looking for guide on path-based proxying in front of Traefik or how to wire Nginx into Appwrite's network without interfering with Traefik's routing.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more