Fix some ansible-lint complaints.

This commit is contained in:
Andreas B. Mundt 2022-06-11 12:42:02 +02:00 committed by Andreas B. Mundt
parent c7030c9245
commit 2cf34e8e55
64 changed files with 357 additions and 297 deletions

View file

@ -1,6 +1,7 @@
## Install and configure nfs-server
---
- fail: msg="The machine's domain must not be empty."
- name: check if ansible domain is nonempty
fail: msg="The machine's domain must not be empty."
when: ansible_domain | length == 0
- name: check if we are installing
@ -11,7 +12,7 @@
apt:
name:
- nfs-kernel-server
state: latest
state: latest # noqa package-latest # noqa package-latest
- name: make sure the export paths exists
file: path={{ export_root }}/home/ state=directory recurse=yes
@ -33,7 +34,7 @@
replace:
path: /etc/hosts
regexp: "^({{ ipaddr_lan | ipaddr('address') }}\\s.+)$"
replace: '\1 nfs'
replace: '\1 nfs'
when: not exports.stat.exists
- name: check if there is a local kadmin
@ -55,7 +56,7 @@
- sssd-krb5
- sssd-ldap
- sssd-tools ## sss_cache -U -G
state: latest
state: latest # noqa package-latest
when: kadmin.stat.exists
- name: provide identities from directory
@ -80,6 +81,7 @@
template:
src: dhcp-send-domain.j2
dest: /etc/dnsmasq.d/dhcp-send-domain
mode: 0644
notify: "restart dnsmasq"
when: dnsmasq.stat.exists
@ -87,6 +89,6 @@
firewalld:
zone: internal
service: nfs
permanent: yes
immediate: yes
permanent: true
immediate: true
state: enabled