summaryrefslogtreecommitdiff
path: root/source4/setup/provision
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2008-03-07 07:38:44 +1100
committerAndrew Bartlett <abartlet@samba.org>2008-03-07 07:38:44 +1100
commit449c0c52428e79ffcaa520c590df468b10397fb3 (patch)
treeeaf0e4ad65284ffe72194d11e1a970da251eea2d /source4/setup/provision
parent8b24d248b7c928fd3b20f95ede34302ca274c4ae (diff)
parent7eaa6b5f9a316d658c3ecf98b44a4cdf8a2de512 (diff)
downloadsamba-449c0c52428e79ffcaa520c590df468b10397fb3.tar.gz
samba-449c0c52428e79ffcaa520c590df468b10397fb3.tar.bz2
samba-449c0c52428e79ffcaa520c590df468b10397fb3.zip
Merge branch 'v4-0-test' of git://git.samba.org/samba into 4-0-local
(This used to be commit a6997c333cdd68dfba8a069df448836ff487787f)
Diffstat (limited to 'source4/setup/provision')
-rwxr-xr-xsource4/setup/provision26
1 files changed, 5 insertions, 21 deletions
diff --git a/source4/setup/provision b/source4/setup/provision
index 033d2491f2..606443a6ed 100755
--- a/source4/setup/provision
+++ b/source4/setup/provision
@@ -30,9 +30,7 @@ import samba
from auth import system_session
import samba.getopt as options
-import param
from samba.provision import (provision,
- provision_paths_from_lp,
FILL_FULL, FILL_NT4SYNC,
FILL_DRS)
@@ -113,27 +111,13 @@ if opts.realm is None or opts.domain is None:
sys.exit(1)
# cope with an initially blank smb.conf
-private_dir = None
-lp = sambaopts.get_loadparm()
-if opts.targetdir is not None:
- if not os.path.exists(opts.targetdir):
- os.mkdir(opts.targetdir)
- private_dir = os.path.join(opts.targetdir, "private")
- if not os.path.exists(private_dir):
- os.mkdir(private_dir)
- lp.set("private dir", os.path.abspath(private_dir))
- lp.set("lock dir", os.path.abspath(opts.targetdir))
-lp.set("realm", opts.realm)
-lp.set("workgroup", opts.domain)
-lp.set("server role", opts.server_role or "domain controller")
+
+if sambaopts.get_loadparm_path() is not None:
+ smbconf = sambaopts.get_loadparm_path()
if opts.aci is not None:
print "set ACI: %s" % opts.aci
-paths = provision_paths_from_lp(lp, opts.realm.lower())
-if sambaopts.get_loadparm_path() is not None:
- paths.smbconf = sambaopts.get_loadparm_path()
-
creds = credopts.get_credentials()
setup_dir = opts.setupdir
@@ -146,8 +130,8 @@ if opts.blank:
elif opts.partitions_only:
samdb_fill = FILL_DRS
-provision(lp, setup_dir, message, paths,
- system_session(), creds,
+provision(setup_dir, message,
+ system_session(), creds, smbconf=smbconf,
samdb_fill=samdb_fill, realm=opts.realm,
domainguid=opts.domain_guid, domainsid=opts.domain_sid,
policyguid=opts.policy_guid, hostname=opts.host_name,