diff --git a/prepare_k8s.yml b/prepare_k8s.yml index d10d7e3..aa388bf 100644 --- a/prepare_k8s.yml +++ b/prepare_k8s.yml @@ -66,4 +66,12 @@ image-endpoint: unix:///run/containerd/containerd.sock timeout: 2 debug: true - pull-image-on-create: false \ No newline at end of file + pull-image-on-create: false + - name: Disable SWAP since kubernetes can't work with swap enabled (1/2) + shell: | + swapoff -a + - name: Disable SWAP in fstab since kubernetes can't work with swap enabled (2/2) + replace: + path: /etc/fstab + regexp: '^([^#].*?\sswap\s+sw\s+.*)$' + replace: '# \1' \ No newline at end of file