From 2ac8d539bee84b818da5ddb6f660fc398a9b7b4c Mon Sep 17 00:00:00 2001 From: Timo Makinen Date: Thu, 14 Apr 2022 13:08:29 +0000 Subject: [PATCH] autofs: Convert modules to use FQCN --- roles/autofs/handlers/main.yml | 2 +- roles/autofs/tasks/main.yml | 20 ++++++++++---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/roles/autofs/handlers/main.yml b/roles/autofs/handlers/main.yml index 673f6a6..d4f56aa 100644 --- a/roles/autofs/handlers/main.yml +++ b/roles/autofs/handlers/main.yml @@ -1,5 +1,5 @@ --- - name: restart autofs - service: + ansible.builtin.service: name: autofs state: restarted diff --git a/roles/autofs/tasks/main.yml b/roles/autofs/tasks/main.yml index 756d120..4ea5acd 100644 --- a/roles/autofs/tasks/main.yml +++ b/roles/autofs/tasks/main.yml @@ -1,24 +1,24 @@ --- - name: install packages - package: + ansible.builtin.package: name: autofs state: installed - name: allow nfs home directories for selinux - seboolean: + ansible.posix.seboolean: name: use_nfs_home_dirs state: true persistent: true - name: configure ldap server for autofs - lineinfile: + ansible.builtin.lineinfile: dest: /etc/autofs.conf regexp: '^#?ldap_uri\s*=.*' line: "ldap_uri = {% for u in ldap_server %}ldaps://{{ u }} {% endfor %}" notify: restart autofs - name: configure ldap schema for autofs - lineinfile: + ansible.builtin.lineinfile: dest: /etc/autofs.conf line: "{{ item }}" insertbefore: "^# auth_conf_file" @@ -31,7 +31,7 @@ - map_object_class = organizationalUnit - name: configure ldap auth for autofs - template: + ansible.builtin.template: dest: /etc/autofs_ldap_auth.conf src: autofs_ldap_auth.conf.j2 mode: 0600 @@ -40,7 +40,7 @@ notify: restart autofs - name: create auto.master config - template: + ansible.builtin.template: dest: /etc/auto.master src: auto.master.j2 mode: 0644 @@ -49,20 +49,20 @@ notify: restart autofs - name: start autofs service - service: + ansible.builtin.service: name: autofs state: started enabled: true - name: disable authorized_keys file from users - lineinfile: + ansible.builtin.lineinfile: path: /etc/ssh/sshd_config line: AuthorizedKeysFile none regexp: '^AuthorizedKeysFile\s+.*' notify: restart sshd - name: enable authorized_keys file for root - blockinfile: + ansible.builtin.blockinfile: path: /etc/ssh/sshd_config block: | Match User root @@ -71,7 +71,7 @@ notify: restart sshd - name: move user cache from home directory to tmpfs - copy: + ansible.builtin.copy: dest: "/etc/profile.d/{{ item }}" src: "{{ item }}" mode: 0644