mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 17:09:03 +00:00
commit
8f8e75c5ff
@ -270,12 +270,6 @@ class Minion(parsers.MinionOptionParser): # pylint: disable=no-init
|
||||
if check_user(self.config['user']):
|
||||
logger.info('The salt minion is starting up')
|
||||
self.minion.tune_in()
|
||||
except (KeyboardInterrupt, SaltSystemExit) as exc:
|
||||
logger.warn('Stopping the Salt Minion')
|
||||
if isinstance(exc, KeyboardInterrupt):
|
||||
logger.warn('Exiting on Ctrl-c')
|
||||
else:
|
||||
logger.error(str(exc))
|
||||
finally:
|
||||
self.shutdown()
|
||||
|
||||
|
@ -38,7 +38,7 @@ import salt.utils.rsax931
|
||||
import salt.utils.verify
|
||||
import salt.version
|
||||
from salt.exceptions import (
|
||||
AuthenticationError, SaltClientError, SaltReqTimeoutError
|
||||
AuthenticationError, SaltClientError, SaltReqTimeoutError, SaltSystemExit
|
||||
)
|
||||
|
||||
import tornado.gen
|
||||
@ -550,7 +550,7 @@ class AsyncAuth(object):
|
||||
'Salt Minion.\nThe master public key can be found '
|
||||
'at:\n{1}'.format(salt.version.__version__, m_pub_fn)
|
||||
)
|
||||
sys.exit(42)
|
||||
raise SaltSystemExit('Invalid master key')
|
||||
if self.opts.get('syndic_master', False): # Is syndic
|
||||
syndic_finger = self.opts.get('syndic_finger', self.opts.get('master_finger', False))
|
||||
if syndic_finger:
|
||||
|
@ -108,10 +108,14 @@ class AsyncRemotePillar(object):
|
||||
'cmd': '_pillar'}
|
||||
if self.ext:
|
||||
load['ext'] = self.ext
|
||||
ret_pillar = yield self.channel.crypted_transfer_decode_dictentry(
|
||||
load,
|
||||
dictkey='pillar',
|
||||
)
|
||||
try:
|
||||
ret_pillar = yield self.channel.crypted_transfer_decode_dictentry(
|
||||
load,
|
||||
dictkey='pillar',
|
||||
)
|
||||
except:
|
||||
log.exception('Exception getting pillar:')
|
||||
raise SaltClientError('Exception getting pillar.')
|
||||
|
||||
if not isinstance(ret_pillar, dict):
|
||||
msg = ('Got a bad pillar from master, type {0}, expecting dict: '
|
||||
|
Loading…
Reference in New Issue
Block a user