remy / nodemon

Monitor for any changes in your node.js application and automatically restart the server - perfect for development
http://nodemon.io/
MIT License
26.21k stars 1.72k forks source link

Restart nodemon through external application #2092

Closed mStirner closed 1 year ago

mStirner commented 1 year ago

Is there a way to restart nodemon from a external call, like a unix socket or http call? Reason for this: I have a application that i distribute as standalone, with its own scope. The application is extendable through plugins.

For not mixing the plugins and the application while developing a plugin, i mount the plugin source into the applications plugin folder (mount --bind ~/projects/OpenHaus/plugins/oh-plg-phoscon/ ~/projects/OpenHaus/backend/plugins/2bba8d0f-e26e-42b6-ae3f-56ec84b339dd/)

The problem with this practice is, nodemon detects not the file changes in the plugin folder. I thought about running 2 nodemon instances, one in the application folder, that starts & restarts the app, and one in the plugin folder, which tell the other nodemon instance "restart the application, the files in the plugin folder has changed"

Any idea how to achieve this?

github-actions[bot] commented 1 year ago

This issue has been automatically marked as idle and stale because it hasn't had any recent activity. It will be automtically closed if no further activity occurs. If you think this is wrong, or the problem still persists, just pop a reply in the comments and @remy will (try!) to follow up. Thank you for contributing <3