42 lines
919 B
YAML
42 lines
919 B
YAML
- name: load distribution-specific values
|
|
include_vars: '{{ item }}'
|
|
with_first_found:
|
|
- '{{ ansible_distribution }}.yml'
|
|
- defaults.yml
|
|
tags:
|
|
- always
|
|
|
|
- name: ensure python3-libdnf5 is installed
|
|
command:
|
|
dnf5 install -y python3-libdnf5
|
|
args:
|
|
creates: /usr/share/licenses/python3-libdnf5
|
|
when: ansible_pkg_mgr == 'dnf5'
|
|
|
|
- name: ensure selinux python bindings are installed
|
|
package:
|
|
name: '{{ selinux_python_libs }}'
|
|
state: present
|
|
notify:
|
|
- gather facts
|
|
tags:
|
|
- install
|
|
|
|
- name: ensure root password is set
|
|
user:
|
|
name: root
|
|
password: '{{ root_password_hash }}'
|
|
when: root_password_hash is defined
|
|
tags:
|
|
- root-user
|
|
- user
|
|
- name: ensure ssh keys are authorized for root login
|
|
ansible.posix.authorized_key:
|
|
user: root
|
|
exclusive: true
|
|
key: '{{ root_authorized_keys }}'
|
|
when: root_authorized_keys is defined
|
|
tags:
|
|
- root-user
|
|
- ssh-key
|