Mejora migraciones con tabla de versiones

This commit is contained in:
2026-02-17 17:22:20 +01:00
parent 8427613114
commit 459523666f
7 changed files with 187 additions and 11 deletions

View File

@@ -0,0 +1,15 @@
CREATE TABLE IF NOT EXISTS db_versions (
version TEXT PRIMARY KEY, -- version semantica x.x.x
notes TEXT,
creation_date TIMESTAMP NOT NULL DEFAULT (now() at time zone 'utc'),
stable BOOLEAN DEFAULT FALSE -- Si la version ha sido testada y se puede desplegar
);
INSERT INTO db_versions (
version,
notes
)
VALUES (
'0.1.0',
'Versión base'
);