Fix config update when config is "null"
When the tunnel reads the config from the server and it is "null" then ignore it. Fixes #1029
This commit is contained in:
parent
b500e556bf
commit
071e4be6a3
|
@ -74,6 +74,15 @@ func (o *Orchestrator) UpdateConfig(version int32, config []byte) *tunnelpogs.Up
|
|||
LastAppliedVersion: o.currentVersion,
|
||||
}
|
||||
}
|
||||
|
||||
if string(config) == "null" {
|
||||
o.log.Info().Msg("Ignore null config from server")
|
||||
o.currentVersion = version
|
||||
return &tunnelpogs.UpdateConfigurationResponse{
|
||||
LastAppliedVersion: o.currentVersion,
|
||||
}
|
||||
}
|
||||
|
||||
var newConf newRemoteConfig
|
||||
if err := json.Unmarshal(config, &newConf); err != nil {
|
||||
o.log.Err(err).
|
||||
|
|
Loading…
Reference in New Issue