mirror of
https://github.com/valitydev/salt.git
synced 2024-11-08 17:33:54 +00:00
Set up dynamic config
This commit is contained in:
parent
3cfb82cdd4
commit
0dfe3aaf31
@ -2979,6 +2979,11 @@ def apply_minion_config(overrides=None,
|
||||
# if there is no beacons option yet, add an empty beacons dict
|
||||
if 'beacons' not in opts:
|
||||
opts['beacons'] = {}
|
||||
|
||||
if overrides.get('ipc_write_buffer', '') == 'dynamic':
|
||||
opts['ipc_write_buffer'] = _DFLT_IPC_WBUFFER
|
||||
if 'ipc_write_buffer' not in overrides:
|
||||
opts['ipc_write_buffer'] = 0
|
||||
|
||||
# if there is no schedule option yet, add an empty scheduler
|
||||
if 'schedule' not in opts:
|
||||
@ -3054,7 +3059,10 @@ def apply_master_config(overrides=None, defaults=None):
|
||||
)
|
||||
opts['token_dir'] = os.path.join(opts['cachedir'], 'tokens')
|
||||
opts['syndic_dir'] = os.path.join(opts['cachedir'], 'syndics')
|
||||
|
||||
if overrides.get('ipc_write_buffer', '') == 'dynamic':
|
||||
opts['ipc_write_buffer'] = _DFLT_IPC_WBUFFER
|
||||
if 'ipc_write_buffer' not in overrides:
|
||||
opts['ipc_write_buffer'] = 0
|
||||
using_ip_for_id = False
|
||||
append_master = False
|
||||
if not opts.get('id'):
|
||||
|
@ -508,7 +508,8 @@ class IPCMessagePublisher(object):
|
||||
def handle_connection(self, connection, address):
|
||||
log.trace('IPCServer: Handling connection to address: {0}'.format(address))
|
||||
try:
|
||||
if self.opts['ipc_write_buffer']:
|
||||
if self.opts['ipc_write_buffer'] > 0:
|
||||
log.trace('Setting IPC connection write buffer: {0}'.format((self.opts['ipc_write_buffer'])))
|
||||
stream = IOStream(
|
||||
connection,
|
||||
io_loop=self.io_loop,
|
||||
|
Loading…
Reference in New Issue
Block a user