add ability to group monitors & proxies#24
Conversation
|
Thank you for the PR! Will have a look! |
jeansaad
left a comment
There was a problem hiding this comment.
I quickly ran the code and noticed that the server url has forward slashes in it when grouped in a folder. I think that grouping should be separate from server name. Wondering if it makes more sense to introduce a namespace property inside the server JSON and use that to do the grouping rather than inferred based on the folder structure. What I would also suggest that u can use slashes to denote folder structure and to potentially ignore any trailing slashes.
Here is an example configuration:
➜ servers cat hello.json
{
"namespace": "@work/hello",
"cwd": "/home/user/dev/work/hello/fe",
"cmd": "python -m http.server",
"env": {
"PATH": "...",
"PORT": 8080
}
}
➜ servers cat api.hello.json
{
"namespace": "@work/hello",
"cwd": "/home/user/dev/work/hello/api",
"cmd": "npm start",
"env": {
"PATH": "...",
"PORT": 8081
}
}
In this example you can configure the name separately from the grouping, hence hello.test and api.hello.test will continue to be separate than the namespace grouping.
Let me know your thoughts! I think it adds a bit more work to your PR but makes it flexible.
|
Thx for the really fast reply 🙂 Yes, had that problem with slashes in the urls and solved it a bit hacky by encoding the server name. That concept looks pretty nice though. Never thought about such a config entry. |
|
@mrohmer, Please let me know if you've had the time to look into this. |
Hey there 🙂
Amazing work your doing here maintaining this awesome tool 🙂
I currently have the pain that ui gets pretty messy when dealing with a hugh amount of servers.
This PR adds the ability to group monitors & proxies within expansion panels by folder structure inside the servers directory.
Given folder structure:
Would result in a ui structure like so: