1
0
Fork 0
mirror of https://github.com/kasmtech/ansible.git synced 2026-07-17 16:46:36 +00:00
kasm-ansible/roles/install_common/tasks/agent.yml

17 lines
421 B
YAML

---
- set_fact:
# We only want to make a swapfile large enough to make up the difference between
# the current swapsize and our desired size.
new_swap_size: "{{ kasm_desired_swap_size | human_to_bytes - current_swap_size.stdout | int }}"
- debug:
var: new_swap_size
- name: Run swap tasks
include_tasks:
file: mkswap.yml
when:
- new_swap_size | int > 0
- not kasm_swapfile.stat.exists