nitrojs / nitro

Next Generation Server Toolkit. Create web servers with everything you need and deploy them wherever you prefer.
https://nitro.build
MIT License
6.24k stars 514 forks source link

Using nitro preset for vercel the preview command after build is no longer working #1140

Open issue-up[bot] opened 1 year ago

issue-up[bot] commented 1 year ago
   Forwarded from downstream issue: - https://github.com/nuxt/nuxt/issues/15672 by @awacode21

### Environment ------------------------------ - Operating System: `Darwin` - Node Version: `v16.16.0` - Nuxt Version: `3.0.0` - Nitro Version: `1.0.0` - Package Manager: `npm@8.11.0` - Builder: `vite` - User Config: `nitro`, `modules` - Runtime Modules: `nuxt-windicss@2.6.0`, `@pinia/nuxt@0.4.6`, `@storyblok/nuxt@4.6.0` - Build Modules: `-` ------------------------------ ### Reproduction https://stackblitz.com/edit/nuxt-starter-subbig ### Describe the bug I setup a new nuxt3 project. I added the nitro configuration to nuxt.config to use the 'vercel' preset. Then do: `npm run build` and afterwards `npm preview` The preview fails with following error message: ``` ERROR Cannot find nitro.json. Did you run nuxi build first? Search path: 13:58:38 [ '/Users/awacode/code/customers/bivignano/website/casa-bivignano/.output/nitro.json', '/Users/awacode/code/customers/bivignano/website/casa-bivignano/nitro.json' ] ``` I saw that with preset vercel it builds to a `.vercel/output` folder but here it is searching for different folders. I would expect that when i use one of the officially documented presets that also the preview command still would work. ### Additional context _No response_ ### Logs _No response_
heikopaiko commented 1 year ago

Any news/ideas on that?