Skip to content

Instantly share code, notes, and snippets.

View danieleparazza's full-sized avatar

danieleparazza

View GitHub Profile
@danieleparazza
danieleparazza / home-assistant-sqlite-postgres-migration-script.md
Last active June 30, 2025 08:16
Home Assistant statistic database migration from SQLite to PostgreSQL

🛠️ Home Assistant History Migration: SQLite → PostgreSQL 17 on TrueNAS (Docker)

This guide helps you migrate full Home Assistant history from the default home-assistant_v2.db (SQLite) to a PostgreSQL 17 instance deployed via TrueNAS SCALE Apps.

It supports:

  • statistics_meta, statistics, statistics_short_term
  • recorder_runs, schema_changes
  • event_types, states_meta, event_data, state_attributes, events, states
@danieleparazza
danieleparazza / hvac_pause.yaml
Last active January 6, 2025 18:33 — forked from raffy-ops/hvac_pause.yaml
HA HVAC Pause Blueprint
#ver. 1.7.1
blueprint:
name: HVAC Pause V1.7.1
description: Pauses HVAC when windows/doors open; resumes last state once closed
domain: automation
source_url: https://gist.github.com/raffy-ops/2bdf967036d8d274fb1f62572ed5e545
input:
climate_device:
description: Climate entity used for climate control.
name: Climate Device