s3-mdssvc: add new option 'spotlight'
authorRalph Boehme <rb@sernet.de>
Thu, 31 Jul 2014 11:49:49 +0000 (13:49 +0200)
committerRalph Böhme <slow@samba.org>
Tue, 7 Jul 2015 15:34:28 +0000 (17:34 +0200)
Per share option: it reflects whether a share is indexed by Tracker or
not. The global switch that controls whether Spotlight is enabled or
not, are the mdsvc RPC switches.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
docs-xml/smbdotconf/misc/spotlight.xml [new file with mode: 0644]
lib/param/param_table.c
source3/param/loadparm.c

diff --git a/docs-xml/smbdotconf/misc/spotlight.xml b/docs-xml/smbdotconf/misc/spotlight.xml
new file mode 100644 (file)
index 0000000..d872bb6
--- /dev/null
@@ -0,0 +1,45 @@
+<samba:parameter name="spotlight"
+                context="S"
+                type="boolean"
+                xmlns:samba="http://www.samba.org/samba/DTD/samba-doc">
+<description>
+       <para>
+         This parameter controls whether Samba allows Spotlight
+         queries on a share. For controlling indexing of filesystems
+         you also have to use Tracker's own configuration system.
+       </para>
+
+       <para>
+         Spotlight has several prerequisites:
+       </para>
+
+       <itemizedlist>
+         <listitem><para>
+           Samba must be configured and built with Spotlight support.
+         </para></listitem>
+
+         <listitem><para>
+           The <emphasis>mdssvc</emphasis> RPC service must be
+           enabled, see below.
+         </para></listitem>
+
+         <listitem><para> Tracker intergration must be setup and the
+         share must be indexed by Tracker.</para></listitem>
+       </itemizedlist>
+
+       <para>For a detailed set of instructions please see <ulink
+       url="https://wiki.samba.org/index.php/Spotlight">https://wiki.samba.org/index.php/Spotlight</ulink>.
+       </para>
+
+       <para>
+      To enable the Spotlight RPC service:
+       </para>
+
+<programlisting>
+<smbconfsection name="[Global]"/>
+<smbconfoption name="rpc_server:mdsvc">embedded</smbconfoption>
+</programlisting>
+
+</description>
+<value type="default">no</value>
+</samba:parameter>
index ff310381213f584cabdb7eac22bccaa2ba5cebf3..148f79c6df4118868b5771f82a815a281b55bd5c 100644 (file)
@@ -807,6 +807,14 @@ struct parm_struct parm_table[] = {
                .special        = NULL,
                .enum_list      = NULL,
        },
+       {
+               .label          = "spotlight",
+               .type           = P_BOOL,
+               .p_class        = P_LOCAL,
+               .offset         = LOCAL_VAR(spotlight),
+               .special        = NULL,
+               .enum_list      = NULL,
+       },
        {
                .label          = "write ok",
                .type           = P_BOOLREV,
index cedaf1a6e60aa0e3954b94c56ce90ad929efc6f1..af74d68fee5ece421bdf4e63b08074df3e529aeb 100644 (file)
@@ -185,6 +185,7 @@ static struct loadparm_service sDefault =
        .access_based_share_enum = false,
        .bAvailable = true,
        .read_only = true,
+       .spotlight = false,
        .guest_only = false,
        .administrative_share = false,
        .guest_ok = false,