Strapi v5 - How to run 2 projects in dev? - Stack Overflow

admin2025-04-16  8

I run a first project with "npm run develop".

When I try to run a second one I got an error due to port 5173 not available.

I follow this doc

to change the port of this 2nd project

  return mergeConfig(config, {
    resolve: {
      alias: {
        '@': '/src',
      },
    },
    server: {
        port: 5174, 
        clientPort: 5174,
    hmr: {
        enabled: true,
        port: 5174,
        clientPort: 5174,
    },
    },
  });
};

But got the same error, this project tries also to use port 5173!

What I did wrong? What should be the right method?

Thanks in advance for any help.

转载请注明原文地址:http://www.anycun.com/QandA/1744801264a87808.html