-- SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Commercial -- SPDX-FileCopyrightText: 2025-2026 Christian Galo -- +goose Up -- Runtime instance settings the console writes at request time (an operator -- clicking something in the UI), distinct from core.integration_config_overrides -- (boot-applied configuration that only takes effect on restart). Keys are -- declared in internal/instance, a small typed registry, so nothing writes an -- ad hoc key here. The first key is the setup banner's deployment-wide -- dismissal (design D12, D28); a later Instance settings page may read this -- table alongside the config overlay, but that page is out of scope here. CREATE TABLE core.instance_settings ( key TEXT NOT NULL PRIMARY KEY, value JSONB NOT NULL, updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(), updated_by TEXT ); -- The init migration's GRANT ON ALL TABLES was point-in-time; new relations -- need their own grants. GRANT ALL ON core.instance_settings TO core_owner, core_writer; GRANT SELECT ON core.instance_settings TO core_reader; -- +goose Down DROP TABLE core.instance_settings;