-- Migration: add status_reason / last_operation / last_error columns to instances
-- Applies to PostgreSQL

BEGIN;

ALTER TABLE instances
    ADD COLUMN IF NOT EXISTS status_reason TEXT,
    ADD COLUMN IF NOT EXISTS last_operation VARCHAR(50),
    ADD COLUMN IF NOT EXISTS last_error TEXT;

COMMIT;

