Forum Discussion
PK_294685
Nimbostratus
Nov 02, 2017Ansible/F5 CSV Lookup with empty cells throws error
Hello F5 Folks,
I started to work on Ansible recently and stuck with below situation. So, i have a csv file to create a node. Each cell has a value something like node-IP, node-name, etc.. The lookup from ansible play works just fine but the problem arises when i lookup a empty cell in csv, f5 throws an error like belowfatal: [testf5 -> localhost]: FAILED! => {"changed": false, "failed": true, "msg": "received exception: Server raised fault: 'Exception caught in LocalLB::urn:iControl:LocalLB/NodeAddressV2::create()\nCommon::InvalidArgument\n'"}
The question arises, why would i lookup a empty cell?
Answer is , I want to create a global csv with at least three nodes(columns) in it and a playbook that looks all 3 node columns in csv to create 3 nodes on f5. If a user want to create only two nodes, f5 throws an error since the cell values will be empty for 3rd node.. So my final requirement is how can i pass empty values to the f5 and not throw an error or skip the play when there are empty values.I appreciate your patience!
- hoolio
Cirrostratus
You can try, but it's not always effective. See this post for details:
Recent Discussions
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects