[Rspamd-Users] Custom Endpoint Issue
Kendall Marino
kendall at beehiiv.com
Tue Sep 16 15:59:41 UTC 2025
Al,
Thank you for the insight; after your message I did try moving the file to
/etc/rspamd/, /etc/rspamd/local.d, and even l/ua.local.d/ and even renaming
it to controller.lua. I've also attempted to update the init.lua file to
reference it directly which was unsuccessful. Am I to understand that there
should be two files, one somewhere in /etc/rspamd/local.d that specifies
some kind of configuration and one in /usr/share/rspamd/rules/controller/
that contains the lua code? Or should I be able to build this endpoint
successfully with just one file? In the logs I see the pre-existing
endpoints being registered, so I feel I must be missing something there.
For what it's worth I did move away from trying to implement the originally
mentioned code for now. I'd like to get this working with the sample code
(what you've shared above from the docs) first before I try to add any more
complexity.
Thanks again,
Kendall
On Fri, Sep 12, 2025 at 6:14 PM Andrew Lewis via Users <
users at lists.rspamd.com> wrote:
> Hi Kendall,
>
> The docs are wrong...
>
> The file should be at $LOCAL_CONFDIR/controller.lua - likely that's
> /etc/rspamd/
>
> It should return results in the following format:
>
> return {
> example = {
> hello = {
> handler = handle_hello,
> enable = false, -- Normal password sufficient for read-only
> operation
> need_task = false,
> }
> }
> }
>
> ...and there would be an endpoint registered at /plugins/example/hello
>
> Best,
> -AL.
> --
> Users mailing list
> Users at lists.rspamd.com
> https://lists.rspamd.com/mailman/listinfo/users
>
More information about the Users
mailing list