_contains_path(nested_dict) → bool¶
Whether the nested dict contains any value that could be a path.
Parameters: nested_dict – The nested dict to evaluate Returns: Return type: bool
is_dev_mode() → bool¶
Detects if flambe was installed in editable mode.
For more information: https://pip.pypa.io/en/latest/reference/pip_install/#editable-installs
Returns: Return type: bool
get_flambe_repo_location() → str¶
Return where flambe repository is located
Returns: The local path where flambe is located Return type: str Raises:
ValueError– If flambe was not installed in editable mode
get_commit_hash() → str¶
Get the commit hash of the current flambe development package.
This will only work if flambe was install from github in dev mode.
Returns: The commit hash Return type: str Raises:
Exception– In case flambe was not installed in dev mode.
rsync_hosts(orch_ip: str, factories_ips: List[str], user: str, folder: str, key: str, exclude: List[str]) → None¶
Rsync the hosts in the cluster.
IMPORTANT: this method is intended to be run in the cluster.
- orch_ip (str) – The Orchestrator’s IP that is visible by the factories (usually the private IP)
- factories_ips (List[str]) – The factories IPs that are visible by the Orchestrator (usually the private IPs)
- user (str) – The username of all machines. IMPORTANT: only machines with same username are supported
- key (str) – The key that communicate all machines
- exclude (List[str]) – A list of files to be excluded in the rsync