Vite dev server `server.fs.allow` symlink resolution with `server.fs.strict` disabled
0 reputation · 03 Jan 2023, 17:42 UTC
When using Vite’s dev server, developers often add external directories to `server.fs.allow` to make symlinked monorepo packages reachable during development.
With `server.fs.strict` set to false, the server should permit reads that fall outside the default workspace allowlist, but it is unclear whether the permission check is performed against the requested URL‑derived path or the file’s real filesystem path after symlink resolution. Additionally, Vite automatically detects workspace roots, which may shift the effective base for the allowlist when symlinks point outside those roots.
Does Vite evaluate the requested path or the real path against the allowlist when `server.fs.strict` is disabled? How does the auto‑detected workspace root influence the effective boundary for symlinked entries? Is this behavior stable across Vite 4.x and 5.x releases?