Open conico974 opened 3 months ago
Using WSL is a good solution if you are able to migrate your project files to within WSL's filesystem (which will require running yarn install
again, since some project dependencies download for the specific OS). Eg. Using git clone
straight from WSL, in a directory other than /mnt/c
. When the project files are on Windows (visible to WSL through the mount), build and deploy time within WSL is incredibly slow (45+ min). This is a known file access issue in WSL2 with the 9P protocol (see issue here).
For anyone that has come here looking for a workaround: we've found it best to use Github Actions to build and deploy, as part of CI/CD, even for development/staging environments. It takes only a few minutes at most, particularly if caching is used. We develop locally on Windows just using next dev
, which just spins up a simple Next.js web server, which is sufficient for web layout, components, etc. Development of the SST side is a bit more tedious (requires a git commit
and git push
on each change), but given how much faster deployment is on Github Actions, is worth it.
Open-next is not properly supported on windows at the moment
There will very likely be issues at runtime. If you are on windows save yourself some time and just use WSL to build. https://learn.microsoft.com/en-us/windows/wsl/install