Files
configpolicy/roles/base/tasks/main.yml
Dustin C. Hatch cbc4d29bd6 r/base: Install python3-libdnf5
Fedora 41 uses _dnf5_ by default.  Being written in C, its Python API is
an optional feature that needs to be installed separately.
2025-01-31 18:55:58 -06:00

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