{{ runbook.description }}

{% if runbook.automated %} Automated {% else %} Manual {% endif %} {% if runbook.requires_approval %} Requires Approval {% endif %}
{% if runbook.services %}
Services
{% for svc in runbook.services %} {{ svc }} {% endfor %}
{% endif %} {% if runbook.alert_names %}
Triggered by Alerts
{% for alert in runbook.alert_names %} {{ alert }} {% endfor %}
{% endif %} {% if runbook.steps %}
Steps
    {% for step in runbook.steps %}
  1. {{ loop.index }}
    {% if step is mapping %}
    {{ step.name or step.title or 'Step ' ~ loop.index }}
    {{ step.description or step.action or '' }}
    {% if step.command %} {{ step.command }} {% endif %} {% else %}
    {{ step }}
    {% endif %}
  2. {% endfor %}
{% endif %} {% if runbook.automation_script %}
Automation Script
{{ runbook.automation_script }}
{% endif %} {% if runbook.success_rate %}
Success Rate
{{ "%.0f"|format(runbook.success_rate * 100) }}%
{% endif %}
{% if runbook.author %} Author: {{ runbook.author }} {% endif %} {% if runbook.last_updated %} Last updated: {{ runbook.last_updated.strftime('%Y-%m-%d') if runbook.last_updated else '—' }} {% endif %}