ejabberd - Comments for "Single Pubsub endpoint for multiple auth_methods" https://www.ejabberd.im/forum/28586/single-pubsub-endpoint-multiple-authmethods en Your question is a good https://www.ejabberd.im/forum/28586/single-pubsub-endpoint-multiple-authmethods#comment-67153 <p>Your question is a good point: if you define an option in host_config, it overrides the global one. This means that defining modules in host_config will override the global modules for that host.</p> <p>Better to use append_host_config instead, so you can have a global common modules, and then append a few modules with different options for each host. See <a href="https://docs.ejabberd.im/admin/guide/configuration/#virtual-hosting" title="https://docs.ejabberd.im/admin/guide/configuration/#virtual-hosting">https://docs.ejabberd.im/admin/guide/configuration/#virtual-hosting</a></p> <p>mod_disco with extra_domains option is just to show that service from private server in the Service Discovery of the public server. I think it's required, but maybe clients are clever enough to not need it...</p> Tue, 25 Oct 2016 16:03:00 +0000 badlop comment 67153 at https://www.ejabberd.im Hi, As always thank you for https://www.ejabberd.im/forum/28586/single-pubsub-endpoint-multiple-authmethods#comment-67152 <p>Hi,</p> <p>As always thank you for promptly addressing the query.<br /> As already mentioned, I have created host_config only for public.domain.com and for private it assumes global module-wise config, the config which I have been using till now.<br /> You have already recommended to create 2 different modules sections. Does that mean, to only define specific modules in either host configs(private/public) which would override global config? And for the rest, global module configs would be used? Should be obvious, but would like to confirm.</p> <p>And also I am not sure about the need to configure mod_disco in this case, if you can please shed some light. As it is working without configuring mod_disco, so could it be something that I am missing from a bigger picture.</p> <p>Thank you,<br /> Prasad</p> Mon, 24 Oct 2016 16:04:59 +0000 prasadv comment 67152 at https://www.ejabberd.im I guess you have something https://www.ejabberd.im/forum/28586/single-pubsub-endpoint-multiple-authmethods#comment-67150 <p>I guess you have something like this:</p> <pre> hosts: - "private.domain.com" - "public.domain.com" </pre><p> I guess the best way (and I hope it works correctly) is to create two different modules sections, one with mod_pubsub, and the other with a disco that redirects to the first pubsub service:</p> <pre> host_config: "private.domain.com": modules: ... mod_disco: {} mod_pubsub: host: "pubsub.private.domain.com" host_config: "public.domain.com": modules: ... mod_disco: extra_domains: - "pubsub.private.domain.com" </pre> Mon, 24 Oct 2016 11:12:31 +0000 badlop comment 67150 at https://www.ejabberd.im