mirror of
https://github.com/k3s-io/k3s-ansible.git
synced 2025-12-25 00:12:37 +01:00
* refactor(ansible): replace deprecated with_items and ansible facts Replace deprecated `with_items` with `loop` keyword across all roles. Migrate from legacy `ansible_*` top-level facts to `ansible_facts['*']` syntax to prepare for ansible-core 2.24 where INJECT_FACTS_AS_VARS will default to False. Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: Aleksei Sviridkin <f@lex.la> * chore(ansible): sync minimum version requirements to 2.15 Align version checks in prereq and airgap roles with README requirement of ansible-core 2.15+. Co-Authored-By: Claude <noreply@anthropic.com> Signed-off-by: Aleksei Sviridkin <f@lex.la> --------- Signed-off-by: Aleksei Sviridkin <f@lex.la> Co-authored-by: Claude <noreply@anthropic.com>
14 lines
494 B
YAML
14 lines
494 B
YAML
---
|
|
- name: Enable cgroup via boot commandline if not already enabled
|
|
ansible.builtin.replace:
|
|
path: /boot/boot.txt
|
|
regexp: '^(setenv bootargs console=ttyS1,115200 console=tty0 root=PARTUUID=\${uuid} rw rootwait smsc95xx.macaddr="\${usbethaddr}"(?!.*\b{{ cgroup_item }}\b).*)$'
|
|
replace: '\1 {{ cgroup_item }}'
|
|
loop:
|
|
- "cgroup_enable=cpuset"
|
|
- "cgroup_memory=1"
|
|
- "cgroup_enable=memory"
|
|
loop_control:
|
|
loop_var: cgroup_item
|
|
notify: Regenerate bootloader image
|