mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
ipaclient: introduce ipaclient.plugins
Load plugins from ipaclient.plugins in client API instances. https://fedorahosted.org/freeipa/ticket/4739 Reviewed-By: David Kupka <dkupka@redhat.com>
This commit is contained in:
parent
9b0df69f75
commit
f1ad3e67ae
@ -1303,6 +1303,7 @@ fi
|
||||
%license COPYING
|
||||
%dir %{python_sitelib}/ipaclient
|
||||
%{python_sitelib}/ipaclient/*.py*
|
||||
%{python_sitelib}/ipaclient/plugins/*.py*
|
||||
%{python_sitelib}/ipaclient-*.egg-info
|
||||
|
||||
|
||||
@ -1315,6 +1316,8 @@ fi
|
||||
%dir %{python3_sitelib}/ipaclient
|
||||
%{python3_sitelib}/ipaclient/*.py
|
||||
%{python3_sitelib}/ipaclient/__pycache__/*.py*
|
||||
%{python3_sitelib}/ipaclient/plugins/*.py
|
||||
%{python3_sitelib}/ipaclient/plugins/__pycache__/*.py*
|
||||
%{python3_sitelib}/ipaclient-*.egg-info
|
||||
|
||||
%endif # with_python3
|
||||
|
7
ipaclient/plugins/__init__.py
Normal file
7
ipaclient/plugins/__init__.py
Normal file
@ -0,0 +1,7 @@
|
||||
#
|
||||
# Copyright (C) 2016 FreeIPA Contributors see COPYING for license
|
||||
#
|
||||
|
||||
"""
|
||||
Sub-package containing all client plugins.
|
||||
"""
|
@ -59,8 +59,10 @@ def setup_package():
|
||||
classifiers=[line for line in CLASSIFIERS.split('\n') if line],
|
||||
platforms = ["Linux", "Solaris", "Unix"],
|
||||
package_dir = {'ipaclient': ''},
|
||||
packages = ["ipaclient",
|
||||
],
|
||||
packages = [
|
||||
"ipaclient",
|
||||
"ipaclient.plugins",
|
||||
],
|
||||
scripts=['../ipa'],
|
||||
data_files = [('share/man/man1', ["../ipa.1"])],
|
||||
)
|
||||
|
@ -913,6 +913,9 @@ class API(plugable.API):
|
||||
if self.env.in_server:
|
||||
import ipaserver.plugins
|
||||
result += (ipaserver.plugins,)
|
||||
else:
|
||||
import ipaclient.plugins
|
||||
result += (ipaclient.plugins,)
|
||||
|
||||
if self.env.context in ('installer', 'updates'):
|
||||
import ipaserver.install.plugins
|
||||
|
Loading…
Reference in New Issue
Block a user