i use the koa template to build my project锛宼hen i can use pm2 to start build/main.js.
you can think about it.
@rikez
nuxt-start
is a command for starting script inside nuxt bin
directory.
pm2
expects script as input (entrypoint).
You can use this command: pm2 start node_modules/nuxt/bin/nuxt-start -i max
It starts nuxt in cluster mode. Don't forget to run build before start.
@manico
This way works for me.
But cannot assign port with --port
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Most helpful comment
@rikez
nuxt-start
is a command for starting script inside nuxtbin
directory.pm2
expects script as input (entrypoint).You can use this command:
pm2 start node_modules/nuxt/bin/nuxt-start -i max
It starts nuxt in cluster mode. Don't forget to run build before start.