Quantcast
Channel: Admins Goodies » www-data
Viewing all articles
Browse latest Browse all 10

chgrp to group I am not a member of

$
0
0

Question

I’m creating git repositories, ldap accounts and ldap groups using PHP application. Everything works fine, but I have a problem to set right permissions to git repositories. Every ldap user is a member of some ldap group, so I want to change group on git repository (regular directory) to specific ldap group. The problem is, that user www-data can’t change group to any other he is not member of. How can I change group after creating directory under apache/www-data user?

www-data@server:/home/git$ mkdir repo.git
www-data@server:/home/git$ chgrp mygroup repo.git
chgrp: changing group of `repo.git/': Operation not permitted
Asked by Peter Krejci

Answer

You either need to make www-data a member of mygroup or use the superuser account to make the change. In either case, you’ll need root access or somebody with root access to help you.

Answered by Lars Kotthoff

Viewing all articles
Browse latest Browse all 10

Trending Articles