Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Not trusting file .hg/hgrc from untrusted user root, group dev

The repository is owned by user root, and group dev

Another user is running hg update on the repository and getting the following messages:

Not trusting file /dev/.hg/hgrc from untrusted user root, group dev Not trusting file .hg/hgrc from untrusted user root, group dev Not trusting file /dev/.hg/hgrc from untrusted user root, group dev Not trusting file /dev/.hg/hgrc from untrusted user root, group dev abort: Permission denied: /dev/src/backend/java/com/tt/afr/schedule/service/ScheduleComparator.java 

In /etc/mercurial/hgrc, we have:

trusted.users=root 

In the home directory of user running hg update, we have this hgrc file:

[trusted] users = root groups = dev 

User is connecting to server using ssh and running the commands.

What can we do to fix this?

like image 393
HyderA Avatar asked Dec 16 '11 14:12

HyderA


1 Answers

Please read the help on trust in Mercurial and make sure that you've added the trust settings on the server. When you connect over SSH, it does not matter who you trust or don't trust locally — it's the hg binary that you run on the server (via the SSH tunnel) that needs to trust the config file.

Also note that you need to put

[trusted] users = root 

in the /etc/mercurial/hgrc file on the server. The section.key = name syntax we use when talking about configuration settings only work on the command line.

like image 151
Martin Geisler Avatar answered Sep 29 '22 08:09

Martin Geisler