{% extends "_base.html" %} {% block title %}Daily Recap — {{ _brand_name }}{% endblock %} {% block content %} {#- Compute totals for AI summary -#} {% set ns = namespace(cluster_count=0, attention_count=0, total_savings=total_potential_savings|default(0)) %} {% for account in insights.data.cloud_accounts %} {% set insights_list = insights.data.insight | selectattr('account_id', 'equalto', account.id) | list %} {% set recommendations = highlight1.data.recommendation_groupings.rows | selectattr('account_id', 'equalto', account.id) | list %} {% set security_events = insights.data.recommendation_security_groupings_v2.rows | selectattr('account_id', 'equalto', account.id) | list %} {% set current_app_event_row = highlight1.data.app_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set current_node_event_row = highlight1.data.node_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set current_pod_event_row = highlight1.data.pod_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set ev_total = (current_app_event_row.event_count if current_app_event_row else 0) + (current_node_event_row.event_count if current_node_event_row else 0) + (current_pod_event_row.event_count if current_pod_event_row else 0) %} {% set has_any_data = (ev_total > 0) or (recommendations | length > 0) or (security_events | length > 0) %} {% if has_any_data %} {% set ns.cluster_count = ns.cluster_count + 1 %} {% if (insights_list | length + recommendations | length + security_events | length + ev_total) > 0 %} {% set ns.attention_count = ns.attention_count + 1 %} {% endif %} {% endif %} {% endfor %}

Daily Recap

I reviewed {{ ns.cluster_count }} cluster{{ 's' if ns.cluster_count != 1 else '' }} overnight. {% if ns.attention_count > 0 %} {{ ns.attention_count }} need{{ 's' if ns.attention_count == 1 else '' }} your attention {% else %} Everything looks healthy {% endif %} {% if ns.total_savings > 0 %} and there's ${{ ns.total_savings | round(2) }}/mo in savings you haven't acted on yet{% if total_opportunity_lost and total_opportunity_lost > 0 %} (${{ total_opportunity_lost | round(2) }} lost in the last 30 days){% endif %}. {% else %}.{% endif %}

OVERVIEW
{% for account in insights.data.cloud_accounts %} {% set c_app = (highlight1.data.app_events.rows | selectattr('account_id', 'equalto', account.id) | first) %} {% set c_node = (highlight1.data.node_events.rows | selectattr('account_id', 'equalto', account.id) | first) %} {% set c_pod = (highlight1.data.pod_events.rows | selectattr('account_id', 'equalto', account.id) | first) %} {% set ev_count = (c_app.event_count if c_app else 0) + (c_node.event_count if c_node else 0) + (c_pod.event_count if c_pod else 0) %} {% set recs = highlight1.data.recommendation_groupings.rows | selectattr('account_id', 'equalto', account.id) | list %} {% set cluster_savings = recs | map(attribute='sum_estimated_savings') | sum %} {% set sec_events = insights.data.recommendation_security_groupings_v2.rows | selectattr('account_id', 'equalto', account.id) | list %} {% set sec_critical = sec_events | map(attribute='count_severity_critical') | sum %} {% set sec_high = sec_events | map(attribute='count_severity_high') | sum %} {% set has_data = (ev_count > 0) or (recs | length > 0) or (sec_events | length > 0) %} {% if has_data %} {% endif %} {% endfor %}
Cluster Events Savings Security  
{{ account.account_name }} {{ ev_count }} {% if cluster_savings > 0 %}${{ cluster_savings | round(2) }}{% else %}—{% endif %} {% if sec_critical > 0 or sec_high > 0 %} {{ sec_critical }}C / {{ sec_high }}H {% else %} {% endif %} View →
{% for account in insights.data.cloud_accounts %} {% set current_app_event_row = highlight1.data.app_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set previous_app_event_row = highlight2.data.app_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set current_app_events = current_app_event_row.event_count if current_app_event_row else 0 %} {% set previous_app_events = previous_app_event_row.event_count if previous_app_event_row else 0 %} {% set current_node_event_row = highlight1.data.node_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set previous_node_event_row = highlight2.data.node_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set current_node_events = current_node_event_row.event_count if current_node_event_row else 0 %} {% set previous_node_events = previous_node_event_row.event_count if previous_node_event_row else 0 %} {% set current_pod_event_row = highlight1.data.pod_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set previous_pod_event_row = highlight2.data.pod_events.rows | selectattr('account_id', 'equalto', account.id) | first %} {% set current_pod_events = current_pod_event_row.event_count if current_pod_event_row else 0 %} {% set previous_pod_events = previous_pod_event_row.event_count if previous_pod_event_row else 0 %} {% set total_highlights = current_app_events + current_node_events + current_pod_events %} {% set recommendations = highlight1.data.recommendation_groupings.rows | selectattr('account_id', 'equalto', account.id) | list %} {% set total_recommendations = recommendations | length %} {% set insights_list = insights.data.insight | selectattr('account_id', 'equalto', account.id) | rejectattr('type', 'equalto', 'Optimization') | list %} {% set total_insights = insights_list | length %} {% set security_events = insights.data.recommendation_security_groupings_v2.rows | selectattr('account_id', 'equalto', account.id) | list %} {% set total_security_events = security_events | length %} {% set total_data = total_highlights + total_recommendations + total_insights + total_security_events %} {% if total_data > 0 %}

{{ account.account_name }}

{#- INSIGHTS -#} {% if total_insights > 0 %}
INSIGHTS
{% for insight in insights_list %}

{% if insight.type == 'Troubleshooting' %} {{ insight.title }} detected for ({{ insight.applications | length }}) workloads {% else %} {{ insight.title }} {% endif %}

{% endfor %} {% endif %} {#- RECOMMENDED ACTIONS -#} {% if total_recommendations > 0 %}
RECOMMENDED ACTIONS
{% set sorted_recommendations = recommendations | sort(attribute='sum_estimated_savings', reverse=True) %} {% for recommendation in sorted_recommendations[:5] %} {% set savings = recommendation.sum_estimated_savings %} {% set rule = recommendation.rule_name %} {% if rule == 'eks_cluster_upgrade' %} {% set link_hash = 'security/cluster-upgrade' %} {% elif rule == 'unused_pvc' %} {% set link_hash = 'optimize/unused-volume' %} {% elif rule == 'pod_right_sizing' %} {% set link_hash = 'optimize/right-sizing' %} {% elif rule == 'pv_rightsize' %} {% set link_hash = 'optimize/pv-rightsizing' %} {% elif rule == 'replica-rightsizing' %} {% set link_hash = 'optimize/replica-rightsizing' %} {% elif rule == 'abandoned-resources' %} {% set link_hash = 'optimize/abandoned-resources' %} {% else %} {% set link_hash = 'optimize/summary' %} {% endif %}

{{ recommendation.count }} {{ rule.replace('_', ' ') }} {% if savings > 0 %} — save ${{ savings | round(2) }}/mo {% endif %}   {% if 'unused' in rule or 'abandoned' in rule %}Clean up{% elif 'right' in rule or 'replica' in rule %}Apply{% else %}Review{% endif %} →

{% endfor %} {% endif %} {#- HIGHLIGHTS -#} {% if total_highlights > 0 %}
HIGHLIGHTS
{% if current_app_events > 0 %}

Application Errors: {{ current_app_events }} {% set diff_app_events = previous_app_events - current_app_events %} {% if previous_app_events == 0 %} (-) {% elif diff_app_events > 0 %} (▼ {{ ((diff_app_events / previous_app_events) * 100) | round(0) }}%) {% elif diff_app_events < 0 %} (▲ {{ ((-diff_app_events / previous_app_events) * 100) | round(0) }}%) {% else %} (-) {% endif %}

{% endif %} {% if current_node_events > 0 %}

Node Errors: {{ current_node_events }} {% set diff_node_events = previous_node_events - current_node_events %} {% if previous_node_events == 0 %} (-) {% elif diff_node_events > 0 %} (▼ {{ ((diff_node_events / previous_node_events) * 100) | round(0) }}%) {% elif diff_node_events < 0 %} (▲ {{ ((-diff_node_events / previous_node_events) * 100) | round(0) }}%) {% else %} (-) {% endif %}

{% endif %} {% if current_pod_events > 0 %}

Pod Errors: {{ current_pod_events }} {% set diff_pod_events = previous_pod_events - current_pod_events %} {% if previous_pod_events == 0 %} (-) {% elif diff_pod_events > 0 %} (▼ {{ ((diff_pod_events / previous_pod_events) * 100) | round(0) }}%) {% elif diff_pod_events < 0 %} (▲ {{ ((-diff_pod_events / previous_pod_events) * 100) | round(0) }}%) {% else %} (-) {% endif %}

{% endif %} {% endif %} {#- SECURITY -#} {% if total_security_events > 0 %}
SECURITY
{% for security_event in security_events %}

{{ security_event.count_severity_critical }} Critical, {{ security_event.count_severity_high }} High, {{ security_event.count_severity_medium }} Medium, {{ security_event.count_severity_low }} Low across {{ security_event.count_image }} images   Fix now →

{% endfor %} {% endif %} {% endif %} {% endfor %} {% endblock %}