I am looking to find vm with 4 CPUs , Please suggest what i am doing wrong 

---
## This playbook is for :

- name: Play with Jason Query for learning it 
  hosts: temp
  gather_facts: yes
  remote_user: root
  tasks:
    - name: Gather facts
      setup:
      register: vm_setup
    - name: Get VM where vCPU=4
      debug:
        msg: "{{ vm_info.results  | json_query(jmesquery) }}"
      vars:
        jmesquery: "[?ansible_processor_vcpus == '4'].ansible_hostname"
      with_items: "{{ vm_setup }}"

-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/e2831022-d6a6-4026-9408-1f771dca81f9%40googlegroups.com.

Reply via email to