From 1af74da2d73c50e4b73988b4c9bcfbccb9a0e471 Mon Sep 17 00:00:00 2001 From: Giorgio Ravera Date: Tue, 27 Oct 2026 11:27:01 +0100 Subject: [PATCH] Added proxmox view --- .storage/lovelace.lovelace_settings | 562 ++++++++++++++++++++++++++++ scripts/home_assistant.yaml | 2 +- 2 files changed, 563 insertions(+), 1 deletion(-) diff --git a/.storage/lovelace.lovelace_settings b/.storage/lovelace.lovelace_settings index 6639dd1e..d20fefad 100644 --- a/.storage/lovelace.lovelace_settings +++ b/.storage/lovelace.lovelace_settings @@ -206,7 +206,569 @@ ] } ] + } + ], + "max_columns": 3, + "path": "config" + }, + { + "type": "sections", + "max_columns": 2, + "title": "Proxmox", + "path": "proxmox", + "icon": "mdi:server", + "sections": [ + { + "type": "grid", + "cards": [ + { + "type": "custom:mushroom-title-card", + "title": "Proxmox Node", + "subtitle": "System overview", + "grid_options": { + "columns": "full", + "rows": "auto" + } + }, + { + "type": "custom:mushroom-chips-card", + "chips": [ + { + "type": "entity", + "entity": "sensor.pve_cpu_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.pve_memory_usage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.pve_memory_usage_percentage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.pve_uptime", + "name": "Uptime" + } + ], + "grid_options": { + "columns": "full" + } + }, + { + "type": "picture", + "image": "/local/images/devices/intel_nuc.png", + "card_mod": { + "style": "ha-card img {\n width: 30% !important;\n margin: auto;\n display: block;\n}\n" + }, + "tap_action": { + "action": "url", + "url_path": "https://pve.giorgioravera.it" + }, + "grid_options": { + "rows": "auto" + } + }, + { + "type": "custom:mushroom-title-card", + "title": "Virtual Machines", + "subtitle": "Status", + "grid_options": { + "columns": "full" + } + }, + { + "type": "custom:mushroom-template-card", + "primary": "Server", + "secondary": "{{ 'RUNNING' if is_state('binary_sensor.pve_server','on') else 'STOPPED' }}\n", + "icon": "mdi:debian", + "icon_color": "{{ 'green' if is_state('binary_sensor.pve_server','on') else 'red' }}\n", + "layout": "horizontal", + "tap_action": { + "action": "more-info" + } + }, + { + "type": "custom:mushroom-template-card", + "primary": "Docker", + "secondary": "{{ 'RUNNING' if is_state('binary_sensor.pve_docker','on') else 'STOPPED' }}\n", + "icon": "mdi:docker", + "icon_color": "{{ 'green' if is_state('binary_sensor.pve_docker','on') else 'red' }}\n", + "layout": "horizontal", + "tap_action": { + "action": "more-info" + } + }, + { + "type": "custom:mushroom-template-card", + "primary": "Firewall", + "secondary": "{{ 'RUNNING' if is_state('binary_sensor.pve_firewall','on') else 'STOPPED' }}\n", + "icon": "mdi:shield-lock", + "icon_color": "{{ 'green' if is_state('binary_sensor.pve_firewall','on') else 'red' }}\n", + "layout": "horizontal", + "tap_action": { + "action": "more-info" + } + }, + { + "type": "custom:mushroom-template-card", + "primary": "Asterisk", + "secondary": "{{ 'RUNNING' if is_state('binary_sensor.pve_asterisk','on') else 'STOPPED' }}\n", + "icon": "mdi:phone", + "icon_color": "{{ 'green' if is_state('binary_sensor.pve_asterisk','on') else 'red' }}\n", + "layout": "horizontal", + "tap_action": { + "action": "more-info" + } + }, + { + "type": "custom:mushroom-template-card", + "primary": "Network", + "secondary": "{{ 'RUNNING' if is_state('binary_sensor.pve_network','on') else 'STOPPED' }}\n", + "icon": "mdi:network", + "icon_color": "{{ 'green' if is_state('binary_sensor.pve_network','on') else 'red' }}\n", + "layout": "horizontal", + "tap_action": { + "action": "more-info" + } + }, + { + "type": "conditional", + "conditions": [ + { + "condition": "or", + "conditions": [ + { + "entity": "binary_sensor.pve_server", + "state": "off" + }, + { + "entity": "binary_sensor.pve_docker", + "state": "off" + }, + { + "entity": "binary_sensor.pve_firewall", + "state": "off" + }, + { + "entity": "binary_sensor.pve_asterisk", + "state": "off" + }, + { + "entity": "binary_sensor.pve_network", + "state": "off" + } + ] + } + ], + "card": { + "type": "custom:mushroom-template-card", + "primary": "Warning", + "secondary": "One or more VMs are stopped", + "icon": "mdi:alert-circle", + "icon_color": "red" + }, + "grid_options": { + "columns": "full" + } + } + ], + "column_span": 2 + }, + { + "type": "grid", + "cards": [ + { + "type": "custom:mushroom-title-card", + "subtitle": "Virtual Machine", + "title": "VM Server" + }, + { + "type": "custom:mushroom-chips-card", + "chips": [ + { + "type": "entity", + "entity": "sensor.server_status", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.server_cpu_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.server_memory_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.server_memory_usage_percentage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.server_uptime", + "name": "Uptime" + } + ] + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.server_start", + "name": "Start VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.server_start" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.server_shutdown", + "name": "Shutdown VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.server_shutdown" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.server_riavvia", + "name": "Reboot VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.server_riavvia" + } + } + } + ] + }, + { + "type": "grid", + "cards": [ + { + "type": "custom:mushroom-title-card", + "subtitle": "Virtual Machine", + "title": "VM Docker" + }, + { + "type": "custom:mushroom-chips-card", + "chips": [ + { + "type": "entity", + "entity": "sensor.docker_status", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.docker_cpu_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.docker_memory_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.docker_memory_usage_percentage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.docker_uptime", + "name": "Uptime" + } + ] + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.docker_start", + "name": "Start VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.docker_start" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.docker_shutdown", + "name": "Shutdown VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.docker_shutdown" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.docker_riavvia", + "name": "Reboot VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.docker_riavvia" + } + } + } + ] + }, + { + "type": "grid", + "cards": [ + { + "type": "custom:mushroom-title-card", + "subtitle": "Virtual Machine", + "title": "VM Firewall" + }, + { + "type": "custom:mushroom-chips-card", + "chips": [ + { + "type": "entity", + "entity": "sensor.firewall_status", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.firewall_cpu_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.firewall_memory_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.firewall_memory_usage_percentage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.firewall_uptime", + "name": "Uptime" + } + ] + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.firewall_start", + "name": "Start VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.firewall_start" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.firewall_shutdown", + "name": "Shutdown VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.firewall_shutdown" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.firewall_riavvia", + "name": "Reboot VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.firewall_riavvia" + } + } + } + ] + }, + { + "type": "grid", + "cards": [ + { + "type": "custom:mushroom-title-card", + "subtitle": "Virtual Machine", + "title": "VM Asterisk" + }, + { + "type": "custom:mushroom-chips-card", + "chips": [ + { + "type": "entity", + "entity": "sensor.asterisk_status", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.asterisk_cpu_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.asterisk_memory_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.asterisk_memory_usage_percentage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.asterisk_uptime", + "name": "Uptime" + } + ] + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.asterisk_start", + "name": "Start VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.asterisk_start" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.asterisk_shutdown", + "name": "Shutdown VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.asterisk_shutdown" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.asterisk_riavvia", + "name": "Reboot VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.asterisk_riavvia" + } + } + } + ] }, + { + "type": "grid", + "cards": [ + { + "type": "custom:mushroom-title-card", + "subtitle": "Virtual Machine", + "title": "VM Network" + }, + { + "type": "custom:mushroom-chips-card", + "chips": [ + { + "type": "entity", + "entity": "sensor.network_status", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.network_cpu_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.network_memory_usage", + "name": "CPU" + }, + { + "type": "entity", + "entity": "sensor.network_memory_usage_percentage", + "name": "RAM" + }, + { + "type": "entity", + "entity": "sensor.network_uptime", + "name": "Uptime" + } + ] + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.network_start", + "name": "Start VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.network_start" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.network_shutdown", + "name": "Shutdown VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.network_shutdown" + } + } + }, + { + "type": "custom:mushroom-entity-card", + "entity": "button.network_riavvia", + "name": "Reboot VM", + "tap_action": { + "action": "call-service", + "service": "button.press", + "target": { + "entity_id": "button.network_riavvia" + } + } + } + ] + } + ], + "cards": [], + "badges": [] + }, + { + "type": "sections", + "max_columns": 2, + "title": "WiFi", + "path": "wifi", + "icon": "mdi:wifi", + "sections": [ { "type": "grid", "cards": [ diff --git a/scripts/home_assistant.yaml b/scripts/home_assistant.yaml index 958ea376..1ed6aa0f 100644 --- a/scripts/home_assistant.yaml +++ b/scripts/home_assistant.yaml @@ -42,7 +42,7 @@ homeassistant_clearlog: - action: system_log.clear - action: recorder.purge data: - keep_days: 6 + keep_days: 30 ###################################################################### # Home Assistant: Sync with Google Home -- 2.47.3