mirror of
https://github.com/freeipa/ansible-freeipa.git
synced 2026-06-10 02:35:54 +00:00
Without this change the "Import variables specific to distribution" tasks fail with "Could not find file on the Ansible Controller..." on environments with inject facts disabled. This changes the tests to run with ansible with inject_facts_as_vars = false and fixes other roles and playbooks.
28 lines
740 B
YAML
28 lines
740 B
YAML
---
|
|
#
|
|
# Example keys for this playbook were generated with the commands:
|
|
# $ openssl genrsa -out private.pem 2048
|
|
# $ openssl rsa -in private.pem -pubout > public.pem
|
|
#
|
|
- name: Tests
|
|
hosts: ipaserver
|
|
become: true
|
|
gather_facts: True
|
|
|
|
tasks:
|
|
- copy:
|
|
src: "{{ playbook_dir }}/public.pem"
|
|
dest: "{{ ansible_facts['env'].HOME }}/public.pem"
|
|
owner: "{{ ansible_user }}"
|
|
group: "{{ ansible_user }}"
|
|
mode: 0600
|
|
- ipavault:
|
|
ipaadmin_password: SomeADMINpassword
|
|
name: asymvault
|
|
username: admin
|
|
vault_type: asymmetric
|
|
vault_public_key_file: "{{ ansible_facts['env'].HOME }}/public.pem"
|
|
- file:
|
|
path: "{{ ansible_facts['env'].HOME }}/public.pem"
|
|
state: absent
|