ensure_scenario_roles
Check and install required Ansible roles for a cyber range scenario, automatically handling missing dependencies to prepare for deployment.
Instructions
Ensure all required roles for a scenario are installed, installing missing ones automatically.
This is the recommended MCP tool to use before deploying a scenario. It will:
Check which roles are required for the scenario
Check which roles are already installed
Automatically install missing Galaxy roles (if auto_install=True)
Automatically clone and install directory-based roles via SSH (if SSH configured)
Report which roles need manual installation (if SSH not configured)
MCP Workflow:
Use
ensure_scenario_roles()before deploying to ensure all roles are readyConfigure SSH access with
configure_ssh_role_installation()for automatic directory-based role installationUse
install_role()to install individual roles as needed
Args: scenario_key: Scenario identifier (e.g., "redteam-lab-intermediate") siem_type: SIEM type if scenario uses SIEM (wazuh, splunk, elastic, security-onion, none) auto_install: Automatically install missing roles (default: True)
Returns: Dictionary with installation status for all required roles
Example: # Ensure all roles are installed before deployment result = await ensure_scenario_roles( scenario_key="redteam-lab-intermediate", siem_type="none", auto_install=True )
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| scenario_key | Yes | ||
| siem_type | No | wazuh | |
| auto_install | No |