mirror of
https://git.bibube.com/nguyen/raspi.git
synced 2024-11-22 22:42:14 +00:00
More files
This commit is contained in:
22
playbooks/add_k3s_requirements.yml
Normal file
22
playbooks/add_k3s_requirements.yml
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
---
|
||||||
|
- name: Ensure required parameters are in /boot/firmware/cmdline.txt
|
||||||
|
hosts: all
|
||||||
|
become: yes
|
||||||
|
tasks:
|
||||||
|
- name: Append kernel parameters to cmdline.txt if not present
|
||||||
|
lineinfile:
|
||||||
|
path: /boot/firmware/cmdline.txt
|
||||||
|
line: "cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory"
|
||||||
|
insertafter: EOF
|
||||||
|
state: present
|
||||||
|
create: yes
|
||||||
|
backup: yes # This creates a backup of the file before making changes
|
||||||
|
notify:
|
||||||
|
- Reboot system
|
||||||
|
|
||||||
|
handlers:
|
||||||
|
- name: Reboot system
|
||||||
|
reboot:
|
||||||
|
msg: "Rebooting system to apply new kernel parameters"
|
||||||
|
reboot_timeout: 600
|
||||||
|
test_command: uptime
|
||||||
Reference in New Issue
Block a user