Replies: 1 comment 1 reply
-
|
This also sounds great, everything in the "mode" would simply override the default settings of the process recursively. Simple, and usable! Every process could have a target mode set by pup start id@mode, if watchdog find a difference in target mode and current mode, it would immediately kill the current process and switch mode? Or should it switch at next restart? Are you interested in implementing this? |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
The idea of this feature is to offer alternate definitions of processes, that make them mutually exclusive:
{ "processes": [ { "id": "frontend", "cmd": "yarn workspace frontend run start", "modes": { // I'm not sure if I prefer an array or an object here "dev": { "cmd": "yarn workspace frontend run dev" } } } ] }Here's how things would work:
defaultpup start frontend@dev api(start frontend with dev mode, api with default mode), orpup start --mode dev frontend api(start frontend and api as dev mode, fallback to default mode)frontend@defaultandfrontend@devat the same time, the cli could offer a prompt to switch mode if another is already runningI haven't thought this through, but I feel it would be a valuable addition.
Use cases:
{ "processes": [ { "id": "bin-thing", "dependsOn": ["database", "broker", "api", ...], "modes": { "mocked": { "dependsOn": [] // Nothing needed to make it run } } } ] }Also, I feel like
processesshould be a record{ processName: processDeclaration }, this would makeidrequired and unique by designBeta Was this translation helpful? Give feedback.
All reactions