mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Use the custom yaml serializer for minion_opts for salt-ssh
Without this change, any OrderedDict instances in our minion_opts (in this case from grains) would be serialized to a format that yaml.safe_load couldn't load. Configuration parsing would error out.
This commit is contained in:
parent
a4a53ecff5
commit
0785438b3f
1 changed files with 2 additions and 1 deletions
|
@ -32,6 +32,7 @@ import salt.log
|
|||
import salt.loader
|
||||
import salt.minion
|
||||
import salt.roster
|
||||
import salt.serializers.yaml
|
||||
import salt.state
|
||||
import salt.utils
|
||||
import salt.utils.args
|
||||
|
@ -655,7 +656,7 @@ class Single(object):
|
|||
'sock_dir': '/',
|
||||
'log_file': 'salt-call.log'
|
||||
})
|
||||
self.minion_config = yaml.dump(self.minion_opts)
|
||||
self.minion_config = salt.serializers.yaml.serialize(self.minion_opts)
|
||||
self.target = kwargs
|
||||
self.target.update(args)
|
||||
self.serial = salt.payload.Serial(opts)
|
||||
|
|
Loading…
Add table
Reference in a new issue