This commit is contained in:
Kekskurse 2023-07-21 06:10:55 +02:00
parent 350e59322c
commit 54b8cb884d
Signed by: kekskurse
GPG Key ID: 728ACCB59341E7E4
1 changed files with 1 additions and 6 deletions

View File

@ -18,12 +18,7 @@
- unp
- name: Create swap file
command: |
{% if swapfile_fallocate %}
fallocate -l {{ ((swapfile_size) | int * 1024 * 1024) }} {{ swapfile_path }}
{% else %}
dd if=/dev/zero of={{ swapfile_path }} bs=1M count={{ swapfile_size }}
{% endif %}
command: dd if=/dev/zero of={{ swapfile_path }} bs=1M count={{ swapfile_size }}
args:
creates: "{{ swapfile_path }}"
register: swapfile_register_create