From 2f2551e6d2b679c3084450cd1711ee626e8d6e2a Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Mon, 27 Nov 2023 17:19:16 +0100 Subject: migrator: Add an escape hatch to allow arbitrary config options Previously only SQL settings and the 'path' for internal storage could be set, and only for SQL and internal storage. input { type = "whatever"; config = { whatever_foobar = "something" } } --- tools/migration/prosody-migrator.lua | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tools/migration') diff --git a/tools/migration/prosody-migrator.lua b/tools/migration/prosody-migrator.lua index 51e2d835..467ecf32 100644 --- a/tools/migration/prosody-migrator.lua +++ b/tools/migration/prosody-migrator.lua @@ -168,6 +168,11 @@ local function prepare_config(host, conf) elseif conf.type == "sql" then cm.set(host, "sql", conf); end + if type(conf.config) == "table" then + for option, value in pairs(conf.config) do + cm.set(host, option, value); + end + end end local function get_driver(host, conf) -- cgit v1.2.3