4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
16 - name: protect grub with root password
18 dest: /etc/grub.d/40_custom
25 password_pbkdf2 root {{ host_os.grub2_password }}
28 - host_os.grub2_password | default(False, True)
30 - name: generate grub config
31 command: /usr/sbin/grub2-mkconfig -o /boot/grub2/grub.cfg
33 - name: chsh/chfn right setting
44 - name: permission change for ssh certificates
52 - /etc/ssh/ssh_host_*_key
54 - name: reload audit config
55 command: augenrules --load
57 - name: Checking existing file id for permission set 0600
60 register: file_perm_status
63 - /var/log/cloud-init.log
64 - /var/log/cloud-init-output.log
67 - /var/log/java_install.log
69 - /var/log/rhsm/rhsmcertd.log
70 - /var/log/rhsm/rhsm.log
71 - /var/log/tuned/tuned.log
73 - /var/log/wpa_supplicant.log
75 - /etc/cron.daily/0yum-daily.cron
76 - /etc/cron.daily/man-db.cron
77 - /etc/cron.hourly/0anacron
78 - /etc/cron.hourly/0yum-hourly.cron
79 - /boot/grub2/grub.cfg
83 - /etc/audit/audit.rules
85 - name: change permission of of files to 0600
87 path: "{{ item.stat.path }}"
90 when: item.stat.exists
91 with_items: "{{ file_perm_status.results }}"
93 - name: delete broken links
98 - find /run/udev/watch/ -xtype l