From 8e6d433df842f158216bd717506f0dfd9f9f97ab Mon Sep 17 00:00:00 2001 From: Thomas Woerner <twoerner@redhat.com> Date: Wed, 3 Jun 2020 12:48:07 +0200 Subject: [PATCH] ipaserver/tasks/install.yml: Always remove temporary pkcs12 copies The created temporary pkcs12 copies need to be removed in all cases. A new task has been added. --- roles/ipaserver/tasks/install.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/roles/ipaserver/tasks/install.yml b/roles/ipaserver/tasks/install.yml index 343ce2a6..30f9da21 100644 --- a/roles/ipaserver/tasks/install.yml +++ b/roles/ipaserver/tasks/install.yml @@ -449,6 +449,16 @@ when: not result_ipaserver_setup_ca.csr_generated | bool + always: + - name: Cleanup temporary files + file: + path: "{{ item }}" + state: absent + with_items: + - "/etc/ipa/.tmp_pkcs12_dirsrv" + - "/etc/ipa/.tmp_pkcs12_http" + - "/etc/ipa/.tmp_pkcs12_pkinit" + when: not ansible_check_mode and not (not result_ipaserver_test.changed and (result_ipaserver_test.client_already_configured is defined or -- GitLab