default=False,
desc='Enable TLS security for all the monitoring stack daemons'
),
+ Option(
+ 'default_cephadm_command_timeout',
+ type='secs',
+ default=15 * 60,
+ desc='Default timeout applied to cephadm commands run directly on '
+ 'the host (in seconds)'
+ ),
]
def __init__(self, *args: Any, **kwargs: Any):
self.device_enhanced_scan = False
self.cgroups_split = True
self.log_refresh_metadata = False
+ self.default_cephadm_command_timeout = 0
self.notify(NotifyType.mon_map, None)
self.config_notify()
image: Optional[str] = "",
env_vars: Optional[List[str]] = None,
log_output: Optional[bool] = True,
+ timeout: Optional[int] = None, # timeout in seconds
) -> Tuple[List[str], List[str], int]:
"""
Run cephadm on the remote host with the given command + args
if not self.mgr.cgroups_split:
final_args += ['--no-cgroups-split']
+ if not timeout:
+ # 15 minute global timeout if no timeout was passed
+ timeout = self.mgr.default_cephadm_command_timeout
+ final_args += ['--timeout', str(timeout)]
+
# subcommand
final_args.append(command)