summaryrefslogtreecommitdiff
path: root/selftest/target
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2009-02-10 18:00:48 +0100
committerStefan Metzmacher <metze@samba.org>2009-02-10 18:07:13 +0100
commitc3baf1529ddd0191e839096ea2e68e3a3457c2d5 (patch)
tree5f563c1dfe429df00348aaa5513ffcee46ed3d10 /selftest/target
parent0d9531e2d3c94c85d607d4b246473d3ce8c3b927 (diff)
downloadsamba-c3baf1529ddd0191e839096ea2e68e3a3457c2d5.tar.gz
samba-c3baf1529ddd0191e839096ea2e68e3a3457c2d5.tar.bz2
samba-c3baf1529ddd0191e839096ea2e68e3a3457c2d5.zip
selftest/Samba4: pass down the kdc address down to provision_raw_*()
metze
Diffstat (limited to 'selftest/target')
-rw-r--r--selftest/target/Samba4.pm29
1 files changed, 16 insertions, 13 deletions
diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm
index 3362eb24a3..7264ddbcb9 100644
--- a/selftest/target/Samba4.pm
+++ b/selftest/target/Samba4.pm
@@ -509,9 +509,9 @@ EOF
#
# provision_raw_prepare() is also used by Samba34.pm!
#
-sub provision_raw_prepare($$$$$$)
+sub provision_raw_prepare($$$$$$$)
{
- my ($self, $prefix, $server_role, $netbiosname, $netbiosalias, $swiface, $password) = @_;
+ my ($self, $prefix, $server_role, $netbiosname, $netbiosalias, $swiface, $password, $kdc_ipv4) = @_;
my $ctx;
-d $prefix or mkdir($prefix, 0777) or die("Unable to create $prefix");
@@ -529,6 +529,7 @@ sub provision_raw_prepare($$$$$$)
$ctx->{netbiosalias} = $netbiosalias;
$ctx->{swiface} = $swiface;
$ctx->{password} = $password;
+ $ctx->{kdc_ipv4} = $kdc_ipv4;
$ctx->{server_loglevel} = 1;
$ctx->{username} = "administrator";
@@ -667,18 +668,18 @@ sub provision_raw_step1($$)
[realms]
$ctx->{realm} = {
- kdc = 127.0.0.1:88
- admin_server = 127.0.0.1:88
+ kdc = $ctx->{kdc_ipv4}:88
+ admin_server = $ctx->{kdc_ipv4}:88
default_domain = $ctx->{dnsname}
}
$ctx->{dnsname} = {
- kdc = 127.0.0.1:88
- admin_server = 127.0.0.1:88
+ kdc = $ctx->{kdc_ipv4}:88
+ admin_server = $ctx->{kdc_ipv4}:88
default_domain = $ctx->{dnsname}
}
$ctx->{domain} = {
- kdc = 127.0.0.1:88
- admin_server = 127.0.0.1:88
+ kdc = $ctx->{kdc_ipv4}:88
+ admin_server = $ctx->{kdc_ipv4}:88
default_domain = $ctx->{dnsname}
}
@@ -767,13 +768,13 @@ sub provision_raw_step2($$$)
return $ret;
}
-sub provision($$$$$$)
+sub provision($$$$$$$)
{
- my ($self, $prefix, $server_role, $netbiosname, $netbiosalias, $swiface, $password) = @_;
+ my ($self, $prefix, $server_role, $netbiosname, $netbiosalias, $swiface, $password, $kdc_ipv4) = @_;
my $ctx = $self->provision_raw_prepare($prefix, $server_role,
$netbiosname, $netbiosalias,
- $swiface, $password);
+ $swiface, $password, $kdc_ipv4);
$ctx->{tmpdir} = "$ctx->{prefix_abs}/tmp";
push(@{$ctx->{directories}}, "$ctx->{tmpdir}");
@@ -895,7 +896,8 @@ sub provision_member($$$)
"localmember3",
"localmember",
3,
- "localmemberpass");
+ "localmemberpass",
+ $dcvars->{SERVER_IP});
$ret or die("Unable to provision");
@@ -928,7 +930,8 @@ sub provision_dc($$)
"localdc1",
"localdc",
1,
- "localdcpass");
+ "localdcpass",
+ "127.0.0.1");
$self->add_wins_config("$prefix/private") or
die("Unable to add wins configuration");