core icon indicating copy to clipboard operation
core copied to clipboard

Remote storage for preview environment not working in workers project

Open k-urtica opened this issue 6 months ago • 2 comments

Describe the bug I have a deployed workers project that uses production and preview environments. Following the documentation, when I run npx nuxt dev --remote=preview, it connects to the production environment's remote storage instead of the preview environment.

Steps to reproduce Steps to reproduce the behavior:

  1. Run npx nuxt dev --remote=preview

The console displays Using production environment and it actually connects to the production environment.

note: nuxthub/core version: "@nuxthub/core": "0.9.0"

Expected behavior When --remote=preview is specified, it should connect to the preview environment.

k-urtica avatar Jun 22 '25 10:06 k-urtica

I have the same issue.

export default defineNuxtConfig({
  $development: {
    hub: {
      remote: "preview",
    },
  },
});
ℹ Using production environment
ℹ Using remote storage from https://project-name.account-name.workers.dev

https://project-name-preview.account-name.workers.dev is expected?

steffbeckers avatar Aug 24 '25 07:08 steffbeckers

Thanks for letting us know about this bug - I'm taking a look into it

RihanArfan avatar Aug 27 '25 19:08 RihanArfan

With the introduction of NuxtHub v0.10 which supports multiple clouds, we're sunsetting NuxtHub Admin. If you stay on NuxtHub v0.9.1 you can specify the project URL for the environment directly:

https://legacy.hub.nuxt.com/docs/getting-started/remote-storage#set-the-project-url

And on NuxtHub v0.10 you can use Nuxt environment overrides/specify custom .env files to connect to different resources.

RihanArfan avatar Dec 10 '25 17:12 RihanArfan