summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-09-09 09:03:23 +1000
committerAndrew Bartlett <abartlet@samba.org>2012-02-29 10:41:07 +0100
commit89fb6da8d074be1f02a9f41d125a407fb44689b0 (patch)
tree55030ba76239e6b43dac2518aa78ce4c8201b0d2
parent265a2bf04f7d9d5203606c47997f4c0c3a9ead5f (diff)
downloadsamba-89fb6da8d074be1f02a9f41d125a407fb44689b0.tar.gz
samba-89fb6da8d074be1f02a9f41d125a407fb44689b0.tar.bz2
samba-89fb6da8d074be1f02a9f41d125a407fb44689b0.zip
selftest: change plugin_dc to test using s3fs
-rwxr-xr-xselftest/target/Samba3.pm73
-rw-r--r--selftest/target/Samba4.pm15
2 files changed, 9 insertions, 79 deletions
diff --git a/selftest/target/Samba3.pm b/selftest/target/Samba3.pm
index 4b0b725d52..9d74e7db48 100755
--- a/selftest/target/Samba3.pm
+++ b/selftest/target/Samba3.pm
@@ -295,79 +295,6 @@ sub setup_admember($$$$)
return $ret;
}
-sub setup_plugin_s4_dc($$$$)
-{
- my ($self, $prefix, $dcvars, $iface) = @_;
-
- print "PROVISIONING S4 PLUGIN AD DC$iface...";
-
- my $plugin_s4_dc_options = "
- workgroup = $dcvars->{DOMAIN}
- realm = $dcvars->{REALM}
-
- security = ads
- domain logons = yes
- passdb backend = samba4
- auth methods = guest samba4
- server signing = on
-
- rpc_server:epmapper = disabled
- rpc_server:rpcecho = disabled
- rpc_server:dssetup = disabled
- rpc_server:svctl = disabled
- rpc_server:ntsvcs = disabled
- rpc_server:eventlog = disabled
- rpc_server:initshutdown = disabled
-
- rpc_server:winreg = embedded
- rpc_server:srvsvc = embedded
- rpc_server:netdfs = embedded
- rpc_server:wkssvc = embedded
- rpc_server:spoolss = embedded
-
- rpc_server:lsarpc = external
- rpc_server:netlogon = external
- rpc_server:samr = external
-
- rpc_daemon:epmd = disabled
- rpc_daemon:lsasd = disabled
- rpc_daemon:spoolssd = disabled
-
- rpc_server:tcpip = no
-
-[IPC\$]
- vfs objects = dfs_samba4
-";
-
- my $ret = $self->provision($prefix,
- "plugindc",
- $iface,
- "pluGin${iface}Pass",
- $plugin_s4_dc_options, 1);
-
- $ret or return undef;
-
- close(USERMAP);
- $ret->{DOMAIN} = $dcvars->{DOMAIN};
- $ret->{REALM} = $dcvars->{REALM};
- $ret->{KRB5_CONFIG} = $dcvars->{KRB5_CONFIG};
-
- # We need world access to this share, as otherwise the domain
- # administrator from the AD domain provided by Samba4 can't
- # access the share for tests.
- chmod 0777, "$prefix/share";
-
- $self->check_or_start($ret,
- "no", "no", "yes");
-
- $self->wait_for_start($ret);
-
- # Special case, this is called from Samba4.pm but needs to use the Samba3 check_env and get_log_env
- $ret->{target} = $self;
-
- return $ret;
-}
-
sub setup_secshare($$)
{
my ($self, $path) = @_;
diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm
index 43d7c8f338..38a434c7c7 100644
--- a/selftest/target/Samba4.pm
+++ b/selftest/target/Samba4.pm
@@ -115,6 +115,7 @@ sub check_or_start($$$)
$ENV{NSS_WRAPPER_PASSWD} = $env_vars->{NSS_WRAPPER_PASSWD};
$ENV{NSS_WRAPPER_GROUP} = $env_vars->{NSS_WRAPPER_GROUP};
+ $ENV{NSS_WRAPPER_WINBIND_SO_PATH} = $env_vars->{NSS_WRAPPER_WINBIND_SO_PATH};
$ENV{UID_WRAPPER} = "1";
@@ -700,6 +701,7 @@ nogroup:x:65534:nobody
SAMBA_TEST_FIFO => "$ctx->{prefix}/samba_test.fifo",
SAMBA_TEST_LOG => "$ctx->{prefix}/samba_test.log",
SAMBA_TEST_LOG_POS => 0,
+ NSS_WRAPPER_WINBIND_SO_PATH => Samba::bindir_path($self, "default/nsswitch/libnss-winbind.so")
};
return $ret;
@@ -760,6 +762,8 @@ sub provision($$$$$$$$$)
posix:sharedelay = 10000
posix:oplocktimeout = 3
posix:writetimeupdatedelay = 500000
+ create mask = 777
+ force create mode = 777
[test1]
path = $ctx->{tmpdir}/test1
@@ -1287,8 +1291,12 @@ sub provision_plugin_s4_dc($$)
my ($self, $prefix) = @_;
my $extra_smbconf_options = "
-server services = -smb
+server services = -smb +s3fs
dcerpc endpoint servers = -unixinfo -rpcecho -spoolss -winreg -wkssvc -srvsvc
+
+[IPC\$]
+ vfs objects = dfs_samba4
+
";
print "PROVISIONING PLUGIN S4 DC...";
@@ -1722,11 +1730,6 @@ sub setup_plugin_s4_dc($$)
$self->wait_for_start($env);
- my $s3_part_env = $self->{target3}->setup_plugin_s4_dc($path, $env, 30);
- unless ($s3_part_env) {
- return undef;
- }
-
$self->{vars}->{plugin_s4_dc} = $env;
return $env;
}