Open the-moog opened 4 years ago
I just did a build of the latest code, with the --dump option. VERY interesting and informative lots of undocuments options. One suggestion, make the --dump option not exit so that the current config enters the log.
I notice that in the dump file (for my config, mostly from mxisd, anyway) there are a worring number of NULL values, should I be worried about that?
No, you shouldn't worry about that. In the case when some feature is disabled then feature's configuration can be null.
What about the issue pf enabling one feature implicitly enabling ones that are not configured?
I haven't found that functions. There are two cases: first, explicitly turn on feature and configure it (or use some defaults parameters), and second, when feature disabled by default or configuration.
For example for authentication it is possible use sql adapter (plain sql or synapse sql), ldap adapter or exec adapter. If you enable authentication then only configured adapters will be used. So if you configure only one exec adapter then only it will be used, sql and ldap adapters will be disabled.
I wrote a little script to hook exec to Django for authentication. I put the following config line in ma1uta.yaml
This caused a flurry of null pointer exceptions
I found that adding
Fixed it.
Conclusion: Enabling a backend enables the sql queries for API aspects of that backend for which there are no usefull defaults or valid config. If there is no useful default or valid config, then perhaps default value for enabled parameter should be false. I think this same issue exists for other backends.
For completeness (as a useful wiki entry for others) here is the auth script. in /etc/ma1sd/wagtail_auth.sh
And it's python couterpart in /opt/site/app/base/management/commands