You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After investigating this preset, I found out it no longer works.
It looks like it's no longer possible to create v6, and v7 is required with new projects.
Therefore the current preset which use v6 and cli v6 is broken:
v6
npx edgio deploy --team=UnJs --site=nitro-deployment --token=$EDGIO_DEPLOY_TOKEN
WARNING: edgio platform serverless runtime supports only Node.js v16. Your current version is v20.2.0.
If your backend code (SSR, Api endpoints, etc.) uses Node.js v20.2.0 features it may not work as expected once deployed on the edgio platform.
🔑 Incorrect apiKey.
Deploy token is invalid or disabled!
v7
npx edgio deploy --property=nitro-deployment --token=$EDGIO_DEPLOY_TOKEN
WARNING: edgio platform serverless runtime supports only Node.js v16. Your current version is v20.2.0.
If your backend code (SSR, Api endpoints, etc.) uses Node.js v20.2.0 features it may not work as expected once deployed on the edgio platform.
🔑 Logged in as "test2" deploy token of site "nitro-deployment".
📋 Deploying to:
> Team: unjs
> Property: nitro-deployment
> branch: edgio
> Environment: default
> Edgio version: 7.0.24
> Commit URL: https://github.com/unjs/nitro-deploys/commit/34bf6dbc08c7fc07211f7525abc1e0b06e0b9b1b
> Deployment #1
🛠️ Building your app for deployment on Edgio
> Bundling router... done.
TypeError: router.fallback is not a function
The v7 upgrade is a breaking change and current Nitro preset doesn't work anymore. I assume no-one uses this preset hence why it's not noticeable (the edgio CLI doesn't use it and edgio users probably use that).
I don't have a way to test v6 apps and the old preset, but we need to either update it to v7 or create a new one and warn that the old one doesn't work for new apps anymore.
It looks like we can/should use their undocumented nitropack connector for Nitro standalone.
For Nuxt we need to use a separated connector.
For the preset implementation, if we follow their instructions we can just run npx edgio init && npx edgio build in the preset, which should auto-detect the framework and use the appropriate connector. Otherwise we're gonna have to manually create all the necessary files, which seems a bad idea as this will need be harder to maintain.
We can create the app in .output, and tell people to run npx edgio init && npx edgio build.
After some testing, I found out that npx edgio init doesn't detect nitropack so we would need to handle this manually.
Maybe the edgio team can help here.
After investigating this preset, I found out it no longer works.
It looks like it's no longer possible to create v6, and v7 is required with new projects.
Therefore the current preset which use v6 and cli v6 is broken:
v6
v7
The v7 upgrade is a breaking change and current Nitro preset doesn't work anymore. I assume no-one uses this preset hence why it's not noticeable (the edgio CLI doesn't use it and edgio users probably use that).
I don't have a way to test v6 apps and the old preset, but we need to either update it to v7 or create a new one and warn that the old one doesn't work for new apps anymore.
It looks like we can/should use their undocumented nitropack connector for Nitro standalone.
For Nuxt we need to use a separated connector.
For the preset implementation, if we follow their instructions we can just run
npx edgio init && npx edgio build
in the preset, which should auto-detect the framework and use the appropriate connector. Otherwise we're gonna have to manually create all the necessary files, which seems a bad idea as this will need be harder to maintain.We can create the app in
.output
, and tell people to runnpx edgio init && npx edgio build
.After some testing, I found out that
npx edgio init
doesn't detectnitropack
so we would need to handle this manually.Maybe the edgio team can help here.
Originally posted by @Hebilicious in nitrojs/nitro-deploys#61 (comment)
The text was updated successfully, but these errors were encountered: