Give a user full right on a dir in /var/www

Alan McKinnon alan at linuxholdings.co.za
Thu Jun 8 16:44:25 UTC 2006


On Thursday 08 June 2006 17:32, OOzy Pal wrote:
> I have made a virtual host in /var/www/vs
>
> How can I give a user full rights on this dir so he can
> read/write/execute without using sudo?

All files and sub-dirs in the dir must be owned by the same group.
Make the user a member of this group.
chmod all files and dirs in the tree to at least g+rwx.

To make life easier in future, set the setgid bit on /var/www/vs and 
*all* sub-dirs recursively. This will ensure that any new files and 
dirs in the entire tree will be owned by the group that 
owns /var/www/vs. This ought to do it:

find /var/www/vs -type d -exec chmod g+s {} \;

-- 
If only me, you and dead people understand hex, 
how many people understand hex?

Alan McKinnon
alan at linuxholdings dot co dot za
+27 82, double three seven, one nine three five




More information about the ubuntu-users mailing list