mirror of
https://github.com/techno-tim/k3s-ansible.git
synced 2025-12-25 18:23:05 +01:00
Change to FQCN with ansible-lint fixer (#553)
* Change to FQCN with ansible-lint fixer Since ansible-base 2.10 (later ansible-core), FQCN is the new way to go. Updated .ansible-lint with a production profile and removed fqcn in skip_list. Updated .yamllint with rules needed. Ran ansible-lint --fix=all, then manually applied some minor changes. * Changed octal value in molecule/ipv6/prepare.yml
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
---
|
||||
- name: Test for cmdline path
|
||||
stat:
|
||||
ansible.builtin.stat:
|
||||
path: /boot/firmware/cmdline.txt
|
||||
register: boot_cmdline_path
|
||||
failed_when: false
|
||||
changed_when: false
|
||||
|
||||
- name: Set cmdline path based on Debian version and command result
|
||||
set_fact:
|
||||
ansible.builtin.set_fact:
|
||||
cmdline_path: >-
|
||||
{{
|
||||
(
|
||||
@@ -20,20 +20,20 @@
|
||||
}}
|
||||
|
||||
- name: Activating cgroup support
|
||||
lineinfile:
|
||||
ansible.builtin.lineinfile:
|
||||
path: "{{ cmdline_path }}"
|
||||
regexp: '^((?!.*\bcgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory\b).*)$'
|
||||
line: '\1 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory'
|
||||
regexp: ^((?!.*\bcgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory\b).*)$
|
||||
line: \1 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory
|
||||
backrefs: true
|
||||
notify: reboot
|
||||
|
||||
- name: Install iptables
|
||||
apt:
|
||||
ansible.builtin.apt:
|
||||
name: iptables
|
||||
state: present
|
||||
|
||||
- name: Flush iptables before changing to iptables-legacy
|
||||
iptables:
|
||||
ansible.builtin.iptables:
|
||||
flush: true
|
||||
|
||||
- name: Changing to iptables-legacy
|
||||
|
||||
Reference in New Issue
Block a user