summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2006-01-22 08:32:34 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:51:20 -0500
commitc95cac9420e513cc2d0bf87992bce60ea2781b55 (patch)
treea9671ab78bd90a59669e2c4499399cbf914600d0 /source4
parenta54a66ddf1504ef1caccc54c1f16c7461916e3b5 (diff)
downloadsamba-c95cac9420e513cc2d0bf87992bce60ea2781b55.tar.gz
samba-c95cac9420e513cc2d0bf87992bce60ea2781b55.tar.bz2
samba-c95cac9420e513cc2d0bf87992bce60ea2781b55.zip
r13063: Add --realm option to upgrade
(This used to be commit e6aa4e92f044712ecaa4bd7099d53d9c7d083c42)
Diffstat (limited to 'source4')
-rwxr-xr-xsource4/setup/upgrade16
1 files changed, 11 insertions, 5 deletions
diff --git a/source4/setup/upgrade b/source4/setup/upgrade
index bfeba716e4..f2d1a870cc 100755
--- a/source4/setup/upgrade
+++ b/source4/setup/upgrade
@@ -13,7 +13,9 @@ options = GetOptions(ARGV,
"POPT_COMMON_CREDENTIALS",
'verify',
'targetdir=s',
- 'quiet', 'blank');
+ 'quiet',
+ 'realm',
+ 'blank');
if (options == undefined) {
println("Failed to parse options");
@@ -44,10 +46,9 @@ Samba4 import tool
provision [options] <libdir> <smbconf>
--targetdir=DIR Output to specified directory
- --quiet Be quiet
- --blank do not add users or groups, just the structure
-
-You must provide at least a realm and domain
+ --quiet Be quiet
+ --blank Do not add users or groups, just the structure
+ --realm=REALM Override realm to use
");
exit(1);
@@ -89,6 +90,11 @@ if (options.targetdir != undefined) {
var creds = options.get_credentials();
var system_session = system_session();
var paths = provision_default_paths(subobj);
+
+if (options.realm != undefined) {
+ subobj.REALM = options.realm;
+}
+
provision(subobj, message, options.blank, paths, system_session, creds);
var ret = upgrade(subobj,samba3,message,paths, system_session, creds);