Skip to content

Migration doesn't seems to work #704

@pieterjanmaes

Description

@pieterjanmaes

I tired the migration for 2 projects, followed the steps, but I always getting following error:

⛅️ wrangler 4.53.0
───────────────────
Using redirected Wrangler configuration.

  • Configuration being used: "server/wrangler.json"
  • Original user's configuration: "../wrangler.jsonc"
  • Deploy configuration file: "../.wrangler/deploy/config.json"

✘ [ERROR] Processing server/wrangler.json configuration:

- Redirected configurations cannot include environments but the following have been found:
    - preview


  Such configurations are generated by tools, meaning that one of the tools
  your application is using is generating the incorrect configuration.
  Report this issue to the tool's author so that this can be fixed there.

Update your nuxt.config.ts to include the following configuration:

export default defineNuxtConfig({
  compatibilityDate: "2025-12-11",
  nitro: {
    preset: "cloudflare_module",
    cloudflare: {
      deployConfig: true,
      nodeCompat: true
    }
  }
})

Create a wrangler.jsonc file in the root of your project with the following configuration:

{
  "$schema": "node_modules/wrangler/config-schema.json",
  "name": "<NAME>",
  "main": "./.output/server/index.mjs",
  "compatibility_date": "2025-12-11",
  "assets": {
    "directory": "./.output/public/",
    "binding": "ASSETS"
  },
  "observability": {
    "enabled": true
  },
  "env": {
    "preview": {}
  }
}

How can I fix this?

Kind regards.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions