Below is my ansible playbook:
- name: create the user ci_user
connection: local
na_ontap_user:
<<: *login
state: present
name: "ci_user"
application_dicts:
- application: ontapi
authentication_methods: password
role_name: ci_readonly
vserver: "{{ cluster }}"
set_password: "{{ password }}"
- name: create the user ci_user
connection: local
na_ontap_user:
<<: *login
state: present
name: "ci_user"
application_dicts:
- application: http
authentication_methods: password
role_name: ci_readonly_rest
vserver: "{{ cluster }}"
But result only gets:
ci_user http password ci_readonly_rest no none
why could not the playbook create 2 user entries? like below:
User/Group Authentication Acct Authentication
Name Application Method Role Name Locked Method
-------------- ----------- ------------- ---------------- ------ --------------
ci_user http password ci_readonly_rest no none
ci_user ontapi password ci_readonly no none
it seems like the second task overwrites the first one completely. But they are different.