diff options
author | Matthieu Patou <mat@matws.net> | 2010-02-08 15:36:07 +0300 |
---|---|---|
committer | Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de> | 2010-02-11 11:47:04 +0100 |
commit | d1c29231511376f4379909401f723b1ea9c538ea (patch) | |
tree | 7917df566776ca28d0d93d8f2c6137d21db843cb /source4 | |
parent | 2cf97c403f73946693bb147daa6a618af6fdb526 (diff) | |
download | samba-d1c29231511376f4379909401f723b1ea9c538ea.tar.gz samba-d1c29231511376f4379909401f723b1ea9c538ea.tar.bz2 samba-d1c29231511376f4379909401f723b1ea9c538ea.zip |
provision: Fix an error with eadb when using not default install dir and running as a non root user
Signed-off-by: Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de>
Diffstat (limited to 'source4')
-rw-r--r-- | source4/scripting/python/samba/provision.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/source4/scripting/python/samba/provision.py b/source4/scripting/python/samba/provision.py index 86f1d9cb07..27e5287457 100644 --- a/source4/scripting/python/samba/provision.py +++ b/source4/scripting/python/samba/provision.py @@ -465,7 +465,11 @@ def make_smbconf(smbconf, setup_path, hostname, domain, realm, serverrole, if os.path.exists(smbconf): default_lp.load(smbconf) if eadb: - posixeadb_line = "posix:eadb = " + os.path.abspath(os.path.join(os.path.join(targetdir, "private"),"eadb.tdb")) + if targetdir is not None: + privdir = os.path.join(targetdir, "private") + else: + privdir = default_lp.get("private dir") + posixeadb_line = "posix:eadb = " + os.path.abspath(os.path.join(privdir,"eadb.tdb")) else: posixeadb_line = "" |