nextjs-starter
nextjs-starter copied to clipboard
Upgrade the deployment settings to now v2
Now v2 has more benefits, just changing the now.json file's version into v2 isn't working. It would be great if someone upgrade zeit now settings to now v2
@aruzikulov I'm also interested in this upgrade - I know that the sample now.json for both NextJS and Express are a bit more complex than changing the number but not much more.... we would basically have to configure the routes.
@iaincollins mind if I take a stab at it and then open a PR for you to review?
NextJS sample
{
"version": 2,
"name": "nextjs",
"builds": [
{ "src": "next.config.js", "use": "@now/next" }
]
}
Express sample
{
"version": 2,
"name": "my-express-project",
"builds": [
{ "src": "www/**/*", "use": "@now/static" },
{ "src": "api/**/*.js", "use": "@now/node" }
],
"routes": [{ "src": "/", "dest": "www/index.html" }]
}
I did a little research and kicked the tires - I'm getting build errors on the routes so it does seem more complicated than I had thought
issues:
Custom Routes Solution
More great discussion...
how-to-deploy-next-js-app-with-custom-express
...which has a nice example by @hvaoc http://unplggd.co which looks promising
github source <-- I'll try his project
demo <-- I was able to deploy it - it just took awhile... first time it timed out but second time it deployed in about 2 minutes - not sure why it takes so long but its working
Ugh thanks!
The changes that are now in Next.js 9 and the release of now.sh were why I let this stall for so long.
I hope to update with the new CSS, API route handling in Next.js, and upgrade it to now.sh 2, with additional config that allows it to also be deployed out of the box on Google Cloud Platform, AWS and AWS Edge.
perfect, can't wait to see your update :)
Ugh thanks!
The changes that are now in Next.js 9 and the release of now.sh were why I let this stall for so long.
I hope to update with the new CSS, API route handling in Next.js, and upgrade it to now.sh 2, with additional config that allows it to also be deployed out of the box on Google Cloud Platform, AWS and AWS Edge.
Any news?