mirror of
https://github.com/techno-tim/k3s-ansible.git
synced 2026-03-12 07:42:11 +01:00
Compare commits
1 Commits
dea28eda11
...
9bceff8ca7
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9bceff8ca7 |
@@ -1,17 +1,7 @@
|
||||
---
|
||||
- name: Test for cmdline path
|
||||
command: grep -E "console=|rootfstype" /boot/cmdline.txt
|
||||
register: boot_cmdline_path
|
||||
failed_when: false
|
||||
changed_when: false
|
||||
|
||||
- name: Set path to cmdline based on test
|
||||
set_fact:
|
||||
cmdline_path: "{{ (boot_cmdline_path.rc == 0) | ternary('/boot/cmdline.txt', '/boot/firmware/cmdline.txt') }}"
|
||||
|
||||
- name: Activating cgroup support
|
||||
lineinfile:
|
||||
path: "{{ cmdline_path }}"
|
||||
path: /boot/firmware/cmdline.txt
|
||||
regexp: '^((?!.*\bcgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory\b).*)$'
|
||||
line: '\1 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory'
|
||||
backrefs: true
|
||||
|
||||
9
site.yml
9
site.yml
@@ -1,13 +1,4 @@
|
||||
---
|
||||
- name: Pre tasks
|
||||
hosts: all
|
||||
pre_tasks:
|
||||
- name: Verify Ansible is version 2.11 or above. (If this fails you may need to update Ansible)
|
||||
assert:
|
||||
that: "ansible_version.full is version_compare('2.11', '>=')"
|
||||
msg: >
|
||||
"Ansible is out of date. See here for more info: https://docs.technotim.live/posts/ansible-automation/"
|
||||
|
||||
- name: Prepare Proxmox cluster
|
||||
hosts: proxmox
|
||||
gather_facts: true
|
||||
|
||||
Reference in New Issue
Block a user