Using Samba as an NT-profile-server
Martin Radford
martin at zamenhof.demon.co.uk
Fri Jan 19 21:10:19 GMT 2001
> Let's say you have two different computer labs which require two different
> profiles, then we want something like this:
>
> [profile]
> path = %H/.profile/__labdependent__/
>
> What would've been great if it was possible to make samba check a file for
> hostnames and if connecting host is found, it should use path= from that
> file. ie:
>
> lab1-h02.domain.com path=%H/.profile/lab1-pc02/
> lab1-h??.domain.com path=%H/.profile/lab1/
> lab2-h??.domain.com path=%H/.profile/lab2/
> lab3-h*.domain.com path=%H/.profile/lab3/
>
> This way, one only need to specify one share. If you have a lot of labs,
> it'll get messy to maintain a config file for all the diff. labs.
A useful addition to Samba would be the ability to take the output of
a command to be part of the smb.conf (as a more general way of doing
Thomas's suggestion above. As an example, I'd like to be
able to do something like the following:
[profile]
path = %H/.profile/`/usr/local/samba/etc/labdependent %M`/
where /usr/local/samba/etc/labdependent would be a script taking a
single argument, and having a string as output. This could be made
arbitrarily complex - for example, you could allow certain users to
connect only from certain machines.
The example uses the backtick character (`) because it's logical in
this context.
I'm not really a coder, so I'm not volunteering to produce a patch.
But does this look like a sensible way of doing this?
Martin
--
Martin Radford | "Only wimps use tape backup: _real_
martin at zamenhof.demon.co.uk | men just upload their important stuff -o)
Registered Linux user #9257 | on ftp and let the rest of the world /\\
- see http://counter.li.org | mirror it ;)" - Linus Torvalds _\_V
More information about the samba
mailing list