Open hopugop opened 2 years ago
Can you, please, clarify your point with a specific example, @hopugop ?
@vladzcloudius when providing custom parameters via scylla_yaml_params
on a playbook:
scylla_yaml_params:
alternator_port: 8000
alternator_write_isolation: only_rmw_uses_lwt
The rest of the default parameters are not applied (except for authenticator
and authorizer
which are overridden by scylla_authentication: True
which is also a default):
https://github.com/scylladb/scylla-ansible-roles/blob/855a7f6a3194646933e8fb0257e362e45cdb75a6/ansible-scylla-node/defaults/main.yml#L194-L200
Only variables present at the user provided scylla_yaml_params
+ overriden by scylla_authentication
are present at the generated yaml:
root@node1-ubuntu:~# egrep 'authorizer:|authenticator:|enable_sstables_mc_format:|internode_compression:|alternator' /etc/scylla/scylla.yaml
authenticator: PasswordAuthenticator
authorizer: CassandraAuthorizer
alternator_port: 8000
alternator_write_isolation: only_rmw_uses_lwt
root@node1-ubuntu:~#
The fix is to merge user-provided scylla_yaml_params
with the ones present at the defaults, and in case there's a conflict, user's should be effective.
Defining
scylla_yaml_params
within a playbook drops all default options for that entry defined in defaults/main.yml. We should extend the defaults rather than erasing them when users provides customscylla_yaml_params
. If the parameters conflict, user's should be effective upon merging.https://github.com/scylladb/scylla-ansible-roles/blob/855a7f6a3194646933e8fb0257e362e45cdb75a6/ansible-scylla-node/defaults/main.yml#L194-L200