|
|
fb9e9a |
From 80aac15de9026055ae2b9972859939cf7925b813 Mon Sep 17 00:00:00 2001
|
|
|
fb9e9a |
From: Thomas Woerner <twoerner@redhat.com>
|
|
|
fb9e9a |
Date: Tue, 30 Jun 2020 17:32:19 +0200
|
|
|
fb9e9a |
Subject: [PATCH] action_plugins/ipaclient_get_otp: Discovered python needed in
|
|
|
fb9e9a |
task_vars
|
|
|
fb9e9a |
|
|
|
fb9e9a |
Ansible is now also supporting discovered_python_interpreter for
|
|
|
fb9e9a |
action_plugins. task_vars needs to be non Null and contain a setting for
|
|
|
fb9e9a |
discovered_python_interpreter. The ipaclient_get_otp action_plugin
|
|
|
fb9e9a |
therefore needed to be adapted.
|
|
|
fb9e9a |
---
|
|
|
fb9e9a |
roles/ipaclient/action_plugins/ipaclient_get_otp.py | 4 ++--
|
|
|
fb9e9a |
roles/ipaclient/tasks/install.yml | 1 -
|
|
|
fb9e9a |
2 files changed, 2 insertions(+), 3 deletions(-)
|
|
|
fb9e9a |
|
|
|
fb9e9a |
diff --git a/roles/ipaclient/action_plugins/ipaclient_get_otp.py b/roles/ipaclient/action_plugins/ipaclient_get_otp.py
|
|
|
fb9e9a |
index dcddc0a..8e04ad9 100644
|
|
|
fb9e9a |
--- a/roles/ipaclient/action_plugins/ipaclient_get_otp.py
|
|
|
fb9e9a |
+++ b/roles/ipaclient/action_plugins/ipaclient_get_otp.py
|
|
|
fb9e9a |
@@ -164,7 +164,8 @@ class ActionModule(ActionBase):
|
|
|
fb9e9a |
return result
|
|
|
fb9e9a |
|
|
|
fb9e9a |
data = self._execute_module(module_name='ipaclient_get_facts',
|
|
|
fb9e9a |
- module_args=dict(), task_vars=None)
|
|
|
fb9e9a |
+ module_args=dict(), task_vars=task_vars)
|
|
|
fb9e9a |
+
|
|
|
fb9e9a |
try:
|
|
|
fb9e9a |
domain = data['ansible_facts']['ipa']['domain']
|
|
|
fb9e9a |
realm = data['ansible_facts']['ipa']['realm']
|
|
|
fb9e9a |
@@ -245,4 +246,3 @@ class ActionModule(ActionBase):
|
|
|
fb9e9a |
finally:
|
|
|
fb9e9a |
# delete the local temp directory
|
|
|
fb9e9a |
shutil.rmtree(local_temp_dir, ignore_errors=True)
|
|
|
fb9e9a |
- run_cmd(['/usr/bin/kdestroy', '-c', tmp_ccache])
|
|
|
fb9e9a |
diff --git a/roles/ipaclient/tasks/install.yml b/roles/ipaclient/tasks/install.yml
|
|
|
fb9e9a |
index 0de3dea..4421f0c 100644
|
|
|
fb9e9a |
--- a/roles/ipaclient/tasks/install.yml
|
|
|
fb9e9a |
+++ b/roles/ipaclient/tasks/install.yml
|
|
|
fb9e9a |
@@ -134,7 +134,6 @@
|
|
|
fb9e9a |
"Password cannot be set on enrolled host" not
|
|
|
fb9e9a |
in result_ipaclient_get_otp.msg
|
|
|
fb9e9a |
delegate_to: "{{ result_ipaclient_test.servers[0] }}"
|
|
|
fb9e9a |
- delegate_facts: yes
|
|
|
fb9e9a |
ignore_errors: yes
|
|
|
fb9e9a |
|
|
|
fb9e9a |
- name: Install - Report error for OTP generation
|
|
|
fb9e9a |
--
|
|
|
fb9e9a |
2.26.2
|
|
|
fb9e9a |
|