From 251fa2147f3ae3aa0557d3baf475af1cf9e0e995 Mon Sep 17 00:00:00 2001 From: Hattshire Date: Mon, 27 Oct 2025 13:48:54 -0300 Subject: [PATCH] Enable MAM and PubSub --- docker-compose.yml | 4 ++-- images/prosody/config/conf.d/default.cfg.lua | 3 ++- images/prosody/config/prosody.cfg.lua | 3 ++- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index b61871e..490379a 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -30,8 +30,8 @@ services: - ADMIN_EMAIL=${ADMIN_EMAIL} - DOMAIN_NAME=${DOMAIN_NAME} - - VIRTUAL_HOST=u.${DOMAIN_NAME} - - LETSENCRYPT_HOST=u.${DOMAIN_NAME} + - VIRTUAL_HOST=u.${DOMAIN_NAME},pubsub.${DOMAIN_NAME} + - LETSENCRYPT_HOST=u.${DOMAIN_NAME},pubsub.${DOMAIN_NAME},${DOMAIN_NAME} env_file: - slidge.env diff --git a/images/prosody/config/conf.d/default.cfg.lua b/images/prosody/config/conf.d/default.cfg.lua index 24a39ff..501a7f9 100644 --- a/images/prosody/config/conf.d/default.cfg.lua +++ b/images/prosody/config/conf.d/default.cfg.lua @@ -7,7 +7,7 @@ then message = "outgoing"; iq = { ["http://jabber.org/protocol/pubsub"] = "both"; - ["http://jabber.org/protocol/pubsub#owner"] = "both"; + ["http://jabber.org/protocol/pubsub#owner"] = "set"; }; } } @@ -15,6 +15,7 @@ then { "whatsapp", "Whatsapp gateway" }; } Component ("u."..ENV_DOMAIN_NAME) "http_file_share" + Component ("pubsub."..ENV_DOMAIN_NAME) "pubsub" Component "whatsapp" component_secret = ENV_SLIDGE_SECRET or "" modules_enabled = {"privilege"} diff --git a/images/prosody/config/prosody.cfg.lua b/images/prosody/config/prosody.cfg.lua index 6882425..bcf0372 100644 --- a/images/prosody/config/prosody.cfg.lua +++ b/images/prosody/config/prosody.cfg.lua @@ -32,7 +32,7 @@ modules_enabled = { "time"; -- Let others know the time here on this server "uptime"; -- Report how long server has been running "version"; -- Replies to server version requests - --"mam"; -- Store recent messages to allow multi-device synchronization + "mam"; -- Store recent messages to allow multi-device synchronization --"turn_external"; -- Provide external STUN/TURN service for e.g. audio/video calls -- Admin interfaces @@ -59,6 +59,7 @@ modules_enabled = { --"welcome"; -- Welcome users who register accounts "http_files"; "privilege"; + "pubsub"; } -- modules_disabled = {}