Improve flag and environment config overrides (#1898)

* Separate overrides from config
* Don't allow changing overridden value
* Write default host and port to config file
* Use existing library value. Hide generated if set
This commit is contained in:
WithoutPants
2021-11-08 10:14:11 +11:00
committed by GitHub
parent 1f48a9ce95
commit 49b2860909
8 changed files with 651 additions and 546 deletions

View File

@@ -252,7 +252,7 @@ func Start(uiBox embed.FS, loginUIBox embed.FS) {
// This can be done before actually starting the server, as modern browsers will
// automatically reload the page if a local port is closed at page load and then opened.
if !c.GetNoBrowserFlag() && manager.GetInstance().IsDesktop() {
if !c.GetNoBrowser() && manager.GetInstance().IsDesktop() {
err = browser.OpenURL(displayAddress)
if err != nil {
logger.Error("Could not open browser: " + err.Error())