fix: Apply linter fixes 🚨
Some checks failed
CI / lint (push) Failing after 13s
CI / release (push) Has been skipped
CI / notify (push) Has been skipped

This commit is contained in:
2024-08-20 11:32:48 +12:00
parent 744235ec45
commit 50725f0195
5 changed files with 18 additions and 16 deletions

View File

@@ -4,15 +4,15 @@ dependencies: []
galaxy_info:
author: cybercinch
description: Install and configure CSF/LFD (https://configserver.com/cp/csf.html)
min_ansible_version: 2.9
min_ansible_version: "2.9"
license: MIT
platforms:
- name: EL
versions:
- 6
- 7
- 8
- 9
- "6"
- "7"
- "8"
- "9"
- name: Debian
versions:
- wheezy

View File

@@ -20,7 +20,7 @@
- name: edit csf.{allow,ignore,pignore,fignore,dyndns}
template:
src: '{{ item }}.j2'
src: '{{ item }}.j2'
dest: '/etc/csf/{{ item }}'
owner: root
group: root
@@ -59,7 +59,7 @@
regexp: '^#{{ item }}\|(.*)$'
line: '{{ item }}|\1'
state: present
backrefs: yes
backrefs: true
loop: '{{ csf_blocklists }}'
when: csf_blocklists is defined
notify:

View File

@@ -5,7 +5,7 @@
service:
name: firewalld
state: stopped
enabled: no
enabled: false
when:
- ansible_facts.os_family == 'RedHat'
- ansible_facts.service_mgr == 'systemd'
@@ -17,7 +17,7 @@
service:
name: ufw
state: stopped
enabled: no
enabled: false
when:
- ansible_facts.distribution == 'Ubuntu'
ignore_errors: true

View File

@@ -5,7 +5,7 @@
package:
name: '{{ item }}'
state: present
update_cache: yes
update_cache: true
with_flattened:
- '{{ csf_required_packages }}'
- '{{ csf_required_packages_dist }}'
@@ -19,7 +19,7 @@
- name: download csf.tgz
get_url:
url: 'https://download.configserver.com/csf.tgz'
url: 'https://download.configserver.com/csf.tgz'
dest: '{{ csf_tmp_dir }}/csf.tgz'
checksum: 'sha256:https://www.configserver.com/checksums.txt'
when: not csf_sbin_file.stat.exists
@@ -27,10 +27,10 @@
- download
- name: unpack csf.tgz
unarchive: # noqa 208
src: '{{ csf_tmp_dir }}/csf.tgz'
unarchive: # noqa 208
src: '{{ csf_tmp_dir }}/csf.tgz'
dest: '{{ csf_tmp_dir }}'
remote_src: yes
remote_src: true
creates: '{{ csf_tmp_dir }}/csf/install.sh'
when: not csf_sbin_file.stat.exists

View File

@@ -4,7 +4,9 @@
- name: include OS-specific variables
include_vars: '{{ item }}'
with_first_found:
- '{{ ansible_facts.os_family }}-{{ ansible_facts.distribution_major_version }}.yml'
- >
{{ ansible_facts.os_family }}-
{{ ansible_facts.distribution_major_version }}.yml
- '{{ ansible_facts.os_family }}.yml'
- 'main.yml'
tags:
@@ -28,7 +30,7 @@
service:
name: '{{ item }}'
state: started
enabled: yes
enabled: true
loop:
- csf
- lfd