[Samba] suggestions about file ownership in multi-user "sandbox"
Matt Mitchell
mmitchell at virtualproperties.com
Wed Aug 18 18:23:15 GMT 2004
Hello all,
We have a directory containing some number (hundreds) of files that are
used as a "sandbox" for development. These files then get deployed by
our application server (they are mostly JSPs with a few other text or
html files sprinkled in). Once people are satisfied with the files,
they are then deployed to the production servers via a batch process.
As a first step in doing some change tracking, I have rigged up this
batch process to automatically submit changed files to a Subversion
repository.
This directory is shared from the Linux server where Samba is running.
All of the people who do this development use Windows and expect to be
able to read and write in this directory. Since logistics and licensing
dictate that there be only one test application server, the implicit
assumption here is that individual working copies are not the best
option. These users additionally have little experience with subversion
or any other VC system.
Given the script that I mentioned above, I can automatically track most
of what we care about (changes, changelogs, etc.), but the one piece of
information I can't capture automatically is the identity of the user
who last changed the file. We have a unified unix-NT user mapping, via
LDAP, which works swimmingly, but it can't account for the fundamental
problem, which is that a file, when edited in place, keeps its original
owner UID.
Obviously this is a feature of filesystem semantics, so my question is
this: does samba provide a hook or feature, similar to the
preexec/postexec script, except for a file write? I am willing to deal
with performance implications, of course. An alternative would be an
unlink-and-create-before-write approach when updating a file, though
that would require samba to do some gymnastics. I'm not aware of any
such feature.
If nothing can be done, I suppose I will have to suggest that we move to
per-user working copies, but if anyone has any other suggestions I'd
love to hear them.
Thanks in advance,
Matt Mitchell
More information about the samba
mailing list