Bug: deployment transfers flatten symlinks into empty files (breaks Next.js/Turbopack builds)

Both rsync and turbo transfers deliver symlinks as empty (0-byte) regular files.
Next.js 16/Turbopack builds place symlinks in .next/node_modules/ (hashed aliases like
"mongoose-8b99e611e7552af3" -> ../../node_modules/mongoose) for externalized server packages.

After deployment these are 0-byte files, so require() resolves empty modules and the app
crashes at runtime ("TypeError: X.Schema is not a constructor"). Verified: local build has
symlinks, deployed release has zero symlinks anywhere under .next (find -type l returns nothing).

Please authenticate to join the conversation.

Upvoters
Status

In Review

Board

πŸ’‘ Feature Request

Date

19 days ago

Author

David Gasperoni

Subscribe to post

Get notified by email when there are changes.