Files
ansible-role-pki/molecule/default/prepare.yml
Jonathan Rosser f03bcc19d5 Add defaults for ownership of installed files on the target
These are currently specified many times in the input data for the
pki role leading to repeated values for each file when in most
cases the ownership is always the same.

This change allows a default owner/group to be set for all installed
files that can be overidden per-certificate if needed.

Change-Id: Ic2cb44e7e28eefcc6afb96e05dd2fcac6e5a7efa
Signed-off-by: Jonathan Rosser <jonathan.rosser@rd.bbc.co.uk>
2025-08-19 15:39:01 +01:00

24 lines
538 B
YAML

---
- name: Prepare
hosts: all
tasks:
- name: Create test group
ansible.builtin.group:
name: test
- name: Create test user
ansible.builtin.user:
name: test
group: test
- name: Update apt cache
ansible.builtin.apt:
update_cache: true
cache_valid_time: 3600
when:
- ansible_facts['os_family'] | lower == 'debian'
- name: Install packages
ansible.builtin.package:
name: "{{ molecule_packages[ansible_facts['os_family'] | lower] }}"