Follow-up from !22: missing default value for cielito_host_users_data
The following discussion from !22 (merged) should be addressed:
-
@apias make this comment on a discussion: Right now, if
cielito_host_username_list
is defined in the inventory but notcielito_host_users_data
, we will get a clear error:TASK [cielito.system.users_and_groups : Loop to build the primary groups of users of the host] *********************************************** task path: /home/apias/desarrolloudelar/ansible3/UdelaRInterior/ansible_collections/cielito/system/roles/users_and_groups/tasks/main.yml:19 fatal: [salado.interior.edu.uy]: FAILED! => {"msg": "Error in jmespath.search in json_query filter plugin:\n{{ cielito_users_data | combine ( cielito_host_users_data, recursive=true )\n| dict2items ( key_name='username' )\n| community.general.json_query( cielito_users_query )\n| items2dict ( key_name='username' )\n}}\n: 'cielito_host_users_data' is undefined. 'cielito_host_users_data' is undefined"}
So, for backward compatibility to really work, we just need to define a value for
cielito_host_users_data
in the defaults.I will open a new issue for this.