Configurations and other related files for Starlight Network infrastructure, made openly available.
at master 36 lines 1.9 kB view raw view rendered
1## [pl-fe](https://codeberg.org/mkljczk/pl-fe) on [Iceshrimp.NET](https://iceshrimp.net) using [Caddy](https://caddyserver.com/) 2 3This is a caddyfile that can be used to configure `pl-fe` against the Iceshrimp.NET fediverse server. 4 5The way it is configured here, all `json`, `ld` and `activity` requests (POST and GET) are passed through to the regular Iceshrimp.NET backend, whereas other requests done from a browser are served `pl-fe`. 6 7There are some exceptions to this, namely routes that are required for the frontend to properly work, as well as federation. 8 9For example, the `/inbox` for the instance, all API routes, `/oauth`, and `/nodeinfo` and `/.well-known` are all *always* passed to the backend. 10 11Refer to [the Caddyfile](Caddyfile) for reference. 12 13## Recommendations 14 15This configuration cannot expose /mod, /queue, /admin and other important routes used for maintaining the instance, and also replaces the default frontend. Sometimes this is undesirable, as such it's recommended to: 16 171. Have a 2nd (sub)domain 182. Point said (sub)domain at your instance's IP Address(es) 193. reverse-proxy it accordingly 204. Configure `AdditionalDomains` option in Iceshrimp.NET's configuration to allow your subdomain 21 22This way you can access the original frontend, admin dash, queue dash and moderation tools from that (sub)domain. 23 24> Rationale here is that all the admin resources *aren't* served from one path, same for the CSS for the oAuth page, but oAuth at least continues to work without the CSS. 25 26## Configuration 27 28To use this, get the latest version of pl-fe according to their upstream instructions, then include stuff from the caddyfile by adding the template, then using `import pl-fe` on your instance. 29 30For example, after importing the relevant snippet, do the following to have it be applied to your instance: 31```caddyfile 32fedi.example.com { 33 import pl-fe 34 reverse_proxy :3000 35} 36```