nuxt / vercel-builder

Vercel Builder for Nuxt
MIT License
645 stars 76 forks source link

Nuxt Internal 500 Error on static build with Vercel #643

Open daletom opened 2 years ago

daletom commented 2 years ago

Hello,

Was deploying a Nuxt.js target: static site using the vercel-builder. It works locally, but when deployed on Vercel, I was getting a 500 level Nuxt Internal Server Error. It was looking a lot like this issue: https://github.com/nuxt/vercel-builder/issues/509

The main difference is that this is not a Nuxt project using content module. It is using Apollo to access an API from Dato CMS. I still tried the recommended fix of deleting the vercel.json file and adding nuxt generate to the build command in Vercel. I no longer get the 500 error, but now the graphql endpoint is just erroring out since it is using nuxt generate. Like below:

image

Any recommendations on still being able to use the vercel-builder to not get the 500 level error? I added it back to show the 500 level error. The site is this: https://datocmstonuxt.vercel.app/. The repo is this: https://github.com/daletom/datocmstonuxt

daletom commented 2 years ago

I'm wondering if this has something to do with Apollo. The reason I am saying that is because I made an identical version of this site just now but used Prismic as the CMS which didn't require me to use Apollo, since they have a '@nuxtjs/prismic' module for the API. It worked here: https://github.com/daletom/prismiccmstonuxt