Closed rymsha closed 3 years ago
Maybe CLI could parse config files (or in some other way) detect or set the main port for XP. Supporting multiple sandbox instances would also be nice, but then a series of ports need to be overridden I guess?
We could provide a simple thing --http.port
argument. This would cover 99% of use-cases.
It's not just 1 port but 5 that are in use. Is this to specify only http port?
Yes.
CLI doesn't check other ports before starting XP. Only 8080
--http.port
would de-hardcode this check to a custom port, but would not to start XP on this specified port.
It sounds confusing, but this is how this are now: CLI "guess" port is always 8080 regardless of XP config. If XP starts on a different port - CLI won't notice it.
Of course to be complete CLI should parse config files and know how to interpret them correctly - but this is not that easy: we support variable substitution and property dependencies in config.
So providing a flag that covers 99% of use cases looks like a simple alternative.
Ok, moving this to Ready
Currently CLI checks if 8080 port is available and refuse to start if is is not available
Port 8080 occupied...
Enonic version: 1.3.0 OS: Linux
enonic sandbox start