ipaclient: remove hard dependency on ipaplatform

Hard-code the user cache directory path in ipaclient.remote_plugins.schema.

https://fedorahosted.org/freeipa/ticket/6474

Reviewed-By: Stanislav Laznicka <slaznick@redhat.com>
This commit is contained in:
Jan Cholasta
2016-11-24 09:52:09 +01:00
committed by Martin Basti
parent 70c3cd7f48
commit a260fd8058
3 changed files with 13 additions and 19 deletions

View File

@@ -21,8 +21,6 @@
This base platform module exports default filesystem paths.
'''
import os
class BasePathNamespace(object):
BASH = "/bin/bash"
@@ -350,17 +348,4 @@ class BasePathNamespace(object):
IPA_GETKEYTAB = '/usr/sbin/ipa-getkeytab'
EXTERNAL_SCHEMA_DIR = '/usr/share/ipa/schema.d'
@property
def USER_CACHE_PATH(self):
return (
os.environ.get('XDG_CACHE_HOME') or
os.path.join(
os.environ.get(
'HOME',
os.path.expanduser('~')
),
'.cache'
)
)
path_namespace = BasePathNamespace