tuttinrete/roles/checkhw/tasks/main.yml

15 lines
354 B
YAML
Raw Normal View History

---
2020-04-29 23:54:11 +02:00
- set_fact:
hwpoints: 1
when: ansible_memtotal_mb|int <= 2048 and ansible_processor_vcpus|int <= 2
2020-04-29 23:54:11 +02:00
- set_fact:
hwpoints: 2
when: ansible_memtotal_mb|int <= 4096 and ansible_processor_vcpus|int <= 2
2020-04-29 23:54:11 +02:00
- set_fact:
hwpoints: 3
when: ansible_memtotal_mb|int > 4096 and ansible_processor_vcpus|int >= 4
2020-04-29 23:11:13 +02:00
2020-04-29 23:54:11 +02:00
- setup: filter=ansible_local