mirror of
https://github.com/Control-D-Inc/ctrld.git
synced 2026-07-04 01:07:49 +02:00
cmd/cli: fix validating remote custom config
Currently, custom config is only validated against invalid syntax, not the validating rules for each configuration value. It causes ctrld process fatal instead of disregarding as expected. To fix this, force the validating rule after fetching remote config. While at it, also add the default network value if non-existed.
This commit is contained in:
committed by
Cuong Manh Le
parent
e578867118
commit
020b814402
@@ -359,6 +359,7 @@ func (p *prog) apiConfigReload() {
|
||||
return
|
||||
}
|
||||
setListenerDefaultValue(cfg)
|
||||
setNetworkDefaultValue(cfg)
|
||||
logger.Debug().Msg("custom config changes detected, reloading...")
|
||||
p.apiReloadCh <- cfg
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user