modoboa-installer
modoboa-installer copied to clipboard
radicale missing library and updated config.tpl
Hi, could you specify it as extension in config dict template and have the possibility to disable it ?
Hi, could you specify it as extension in config dict template and have the possibility to disable it ?
Will have a look into it. 😉
@Spitfireap looked into the option to make it optional and have a question about how you meant it. I found two possible ways that looked reasonable to me:
-
make it a as a part of the modoboa.extensions config - it would be there by default and could be deleted at will - based on this during the modoboa installation and configuration, if this extension would be present, it would modify the radicale configuration appropriately
-
add a new configuration option under radicale (for example auth_method), that woudl default to radicale_dovecot_auth (as it is now) but could be changed to radicale_modoboa_token_auth (or any other available method) - based on this setting if the radicale_modoboa_token_auth method would be specified, it would install the additional package. After looking into the installer, it looks to me that the installer cannot comment / uncomment (add / remove) config lines based on the config.tpl file - so I would include the two related config options (radicale_modoboa_token_auth_check_url and radicale_modoboa_token_auth_token) by default commented - but if it is possible to dymamically add / remove / comment / uncomment lines using the config.tpl, it would do it properly; and also it would require a little comment explaining what it is
I prefer the scenario number 2. What is your thought or did you have anything else on your mind?
Hey,
I agree with you for number 2. As for commenting/uncommenting at run time, you can take a look at this, it is used here for instance. You could simply add a check for the auth mechanism in get_template_context
on radicale.py. :)
@tomas-kucera Option 2 looks indeed better and @Spitfireap suggestion for config file is interesting but you're right, it is not easy to add/remove lines to templates because I tried to avoid including external deps to the installer. One question I'm curious about : how did you end up installing this authentication plugin?
I fully support the minimalistic dependency approach. I seem to be able to conditionally add lines though. I have it prepared, just need to test it yet.
The answer to your question is very simple. I wanted to be able to share calendar (read-only) publicly to anyone without the need to be a user of the same domain. And so the token based sharing was my choice. But it did not work and by debugging I found that this is what is missing. After installation and configuration I was able to achieve what I wanted. 😉
I had a chat about with @Spitfireap on Discord about it and decided to make it a PR.