Skip to content

Explain how to reach a NAS on a private network in the File Search wizard - #1805

Merged
helpcodeai merged 1 commit into
mainfrom
feat/file-search-nas-reachability
Nov 20, 2026
Merged

helpcodeai merged 1 commit into
mainfrom
feat/file-search-nas-reachability

Conversation

@helpcodeai

Copy link
Copy Markdown
Contributor

Summary

People who open File Search to search their NAS usually type the NAS's LAN address (192.168.x.x, nas.local) or a Synology QuickConnect link. AnythingMCP Cloud cannot reach those, and until now the wizard only showed a one-line error. In the last two days every new File Search account that tried this stopped there, mostly on the Synology preset with private_address or unreachable errors.

This PR explains, right in the wizard, how to make the NAS reachable from the internet.

Changes

  • lib/private-host.ts: recognises private IPs (RFC 1918, loopback, link-local, CGNAT/Tailscale, IPv6 ULA/link-local), names without a dot, home-network suffixes (.local, .lan, .fritz.box…) and QuickConnect links. It is only a hint; the backend SSRF guard still decides what can be connected.
  • components/file-search/nas-reachability-help.tsx: a help box with three ways to make the NAS reachable: Synology WebDAV over HTTPS with a free synology.me name and Let's Encrypt; a tunnel (Cloudflare Tunnel, Tailscale Funnel); QNAP, Fritz!Box and other NAS. It also shows the Cloud's outbound address(es) for the NAS firewall, mentions self-hosting, and has a "Switch to WebDAV" button.
  • File Search wizard:
    • Step 1 shows the box while the address typed is private or a QuickConnect link.
    • Step 2 shows it when the test fails with private_address, unreachable or timeout.
    • Both only on Cloud (capabilities.cloud).
  • Strings in en, de, it.

Type

  • Bug fix
  • New feature
  • Documentation
  • Refactoring
  • Performance improvement
  • Other (describe below)

Cloud and self-hosted

  • Cloud: the help box shows as described above.
  • Self-hosted: nothing changes. The box never shows there, because a self-hosted instance can reach the LAN once an admin allows the host.

Testing

  • Added/updated tests: tests/e2e/file-search-nas-reachability.spec.ts, 4 tests with mocked API:
    • a private address shows the help, and Switch to WebDAV changes the form;
    • a QuickConnect link is called out;
    • a public address shows the help only after a failed test;
    • a self-hosted instance shows none of it.
  • Tested manually: screenshots of step 1 at 1280 px and 390 px wide.

Commands and results, all in packages/frontend:

  • npx tsc --noEmit -p tsconfig.json: no errors.
  • npx eslint on the changed files: 0 errors, 1 warning that already exists (react-hooks/set-state-in-effect on loadCaps, untouched).
  • next dev --webpack --port 3100, then PLAYWRIGHT_USE_RUNNING_SERVER=1 npx playwright test tests/e2e/file-search-nas-reachability.spec.ts --workers=1: 4 passed.
  • The full Playwright suite was not run locally.

Checklist

  • My code follows the existing code style
  • I have tested my changes locally
  • I have updated documentation (if applicable): there is no File Search page in docs/; the guidance lives in the product
  • All existing tests pass (npm test): frontend-only change; the frontend has no npm test
  • This PR has a descriptive title

Related Issues

None. No backend or ee/ change.

…zard

On Cloud, a NAS address that only works inside the user's network
(192.168.x.x, nas.local, a QuickConnect link) or a connection test that
cannot reach the server now shows how to make the NAS reachable: Synology
WebDAV over HTTPS with a synology.me name, a tunnel, other NAS, the Cloud's
outbound address for the firewall, and a switch to WebDAV. Self-hosted
instances are unchanged.
@helpcodeai
helpcodeai merged commit bea5502 into main Nov 20, 2026
17 checks passed
@helpcodeai
helpcodeai deleted the feat/file-search-nas-reachability branch November 20, 2026 07:26
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant