Skip to content

Commit 40bd0d9

Browse files
Added swapoff -a preKubeadmCommand to all templates. (#59)
* Added swapoff -a preKubeadmCommand to all templates. * v0.2.1 release files
1 parent f53f04b commit 40bd0d9

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

templates/cluster-template-managed-ssh.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ spec:
4747
kubeletExtraArgs:
4848
provider-id: "cloudstack:///'{{ ds.meta_data.instance_id }}'"
4949
name: '{{ local_hostname }}'
50+
preKubeadmCommands:
51+
- swapoff -a
5052
infrastructureTemplate:
5153
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha3
5254
kind: CloudStackMachineTemplate
@@ -111,4 +113,6 @@ spec:
111113
kubeletExtraArgs:
112114
provider-id: "cloudstack:///'{{ ds.meta_data.instance_id }}'"
113115
name: '{{ local_hostname }}'
116+
preKubeadmCommands:
117+
- swapoff -a
114118

templates/cluster-template-ssh-material.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ spec:
5252
sshAuthorizedKeys:
5353
- ${SSH_KEY_MATERIAL}
5454
sudo: ALL=(ALL) NOPASSWD:ALL
55+
preKubeadmCommands:
56+
- swapoff -a
5557
infrastructureTemplate:
5658
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha3
5759
kind: CloudStackMachineTemplate
@@ -119,4 +121,5 @@ spec:
119121
sshAuthorizedKeys:
120122
- ${SSH_KEY_MATERIAL}
121123
sudo: ALL=(ALL) NOPASSWD:ALL
122-
124+
preKubeadmCommands:
125+
- swapoff -a

templates/cluster-template.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ spec:
4747
kubeletExtraArgs:
4848
provider-id: "cloudstack:///'{{ ds.meta_data.instance_id }}'"
4949
name: '{{ local_hostname }}'
50+
preKubeadmCommands:
51+
- swapoff -a
5052
infrastructureTemplate:
5153
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha3
5254
kind: CloudStackMachineTemplate
@@ -109,4 +111,6 @@ spec:
109111
kubeletExtraArgs:
110112
provider-id: "cloudstack:///'{{ ds.meta_data.instance_id }}'"
111113
name: '{{ local_hostname }}'
114+
preKubeadmCommands:
115+
- swapoff -a
112116

0 commit comments

Comments
 (0)