Self hosting lemmy: does it support subpath URLs?

https://lemmy.world/post/227939

Self hosting lemmy: does it support subpath URLs? - Lemmy.world

Hi! I want to self host lemmy on my homelab. I have a lot of services installed but only a couple of them are exposed on the internet using subpaths like host.com/plex [http://host.com/plex] or host.com/nextcloud [http://host.com/nextcloud]. I want to do the same with lemmy, so host.com/lemmy [http://host.com/lemmy]. Does lemmy support this particular URL configuration? Thank you!

I don't know if lemmy supports sub-paths, I've never seen a lemmy hosted at one though. If it doesn't nginx definitely supports vhosts. So a single server/vm/container can definitely respond both at my.host.com and lemmy.host.com with appropriate content.
It won’t work well. Other instances make assumptions about paths as it’s standardized. For example they don’t store the full pictrs path, just the ID. It’s assumed the path is /pictrs/image.

From a security point of view it is not a good idea to host multiple web applications in sub directories on the same hostname. With such a configuration, every application sees all cookies from all other applications. This also means that you can have collisions of cookie names between applications if the names are not unique.

So if one application would ge compromised, it could easily steal all your sessions for all other applications.

Oh, I didn't think about that!