runtipi/packages/worker/assets/migrations/00008-merge-config-with-domain-and-exposed.sql
2023-11-16 20:49:27 +01:00

14 lines
323 B
SQL

-- For all apps that have a domain or exposed field set merge those values into the config jsonb
UPDATE
app
SET
config = jsonb_set(config, '{domain}', to_jsonb (DOMAIN))
WHERE
DOMAIN IS NOT NULL;
UPDATE
app
SET
config = jsonb_set(config, '{exposed}', to_jsonb (exposed))
WHERE
exposed IS NOT NULL;