mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2024-12-20 14:13:08 +00:00
Filter deviceConfig values that will be stored as current values to only include relevant keys
Otherwise, devices where we update from legacy supervisors might have other keys, like RESIN_SUPERVISOR_DELTA, stored in deviceConfig.values, causing `_.isEqual(values, targetValues)` to always return false. Signed-off-by: Pablo Carranza Velez <pablo@resin.io>
This commit is contained in:
parent
c05474b1a9
commit
e0d1d89419
@ -511,7 +511,8 @@ specialActionConfigKeys = _.map(specialActionConfigVars, 0)
|
||||
executedSpecialActionConfigVars = {}
|
||||
|
||||
executeSpecialActionsAndHostConfig = (conf, oldConf, opts) ->
|
||||
updatedValues = _.clone(oldConf)
|
||||
updatedValues = _.pickBy _.clone(oldConf), (val, key) ->
|
||||
_.startsWith(key, device.hostConfigConfigVarPrefix) or _.includes(specialActionConfigKeys, key)
|
||||
needsReboot = false
|
||||
Promise.mapSeries specialActionConfigVars, ([ key, specialActionCallback ]) ->
|
||||
# This makes the Special Action Envs only trigger their functions once.
|
||||
|
Loading…
Reference in New Issue
Block a user