kubespray/roles/kubernetes
Max Gautier 2c3ea84e6f
Use systemd for disabling swap when it's used (#10587)
* Mask systemd swap.target do disable swap

This is a more generic way to disable swap, since it pulls .swap units
in systemd distributions; fstab is only one way to generate .swap units.

* Unconditionally disable swap

We only care to disable it (the "swapon" registered variable is not used
anywhere else.
This allows to get rid of the ignore_errors, since this was added
because swapon.stdout does not exist in check_mode (see issue #6642).

* Don't explicitly disable swapOnZram

We're already masking the swap.target, which would pull the zram unit,
hence no need to handle zram-generator specifically.
2023-12-07 13:26:21 +01:00
..
client Resolve ansible-lint name errors (#10253) 2023-07-26 07:36:22 -07:00
control-plane add kube_apiserver_etcd_compaction_interval (#10644) 2023-11-27 05:37:33 +01:00
kubeadm Refactor "multi" handlers to use listen (#10542) 2023-11-08 12:28:30 +01:00
node Check conntrack module presence instead of kernel version (#10662) 2023-11-28 18:31:02 +01:00
node-label/tasks project: fix var-spacing ansible rule (#10266) 2023-07-04 20:36:54 -07:00
preinstall Use systemd for disabling swap when it's used (#10587) 2023-12-07 13:26:21 +01:00
tokens Resolve ansible-lint name errors (#10253) 2023-07-26 07:36:22 -07:00