3

I was tried to setup git and gitosis for our projects. For the gitosis setup, I'm following this article http://scie.nti.st/2007/11/14/hosting-git-repositories-the-easy-and-secure-way as this is first time using git.

I got an issue when I run the gitosis-init. I don't know what happen or how to check.

Please help me on what I need to check or do. In fact, I don't even know whether this is a problem as I just started using Linux, git and etc.

Reinitialized existing Git repository in /home/git/repositories/gitosis-admin.git/
Reinitialized existing Git repository in /home/git/repositories/gitosis-admin.git/
Traceback (most recent call last):
  File "/usr/bin/gitosis-init", line 8, in <module>
    load_entry_point('gitosis==0.2', 'console_scripts', 'gitosis-init')()
  File "/usr/lib/python2.5/site-packages/gitosis-0.2-py2.5.egg/gitosis/app.py", line 24, in run
    return app.main()
  File "/usr/lib/python2.5/site-packages/gitosis-0.2-py2.5.egg/gitosis/app.py", line 38, in main
    self.handle_args(parser, cfg, options, args)
  File "/usr/lib/python2.5/site-packages/gitosis-0.2-py2.5.egg/gitosis/init.py", line 140, in handle_args
    run_hook.post_update(cfg=cfg, git_dir=admin_repository)
  File "/usr/lib/python2.5/site-packages/gitosis-0.2-py2.5.egg/gitosis/run_hook.py", line 40, in post_update
    path=os.path.join(generated, 'projects.list'),
  File "/usr/lib/python2.5/site-packages/gitosis-0.2-py2.5.egg/gitosis/gitweb.py", line 109, in generate_project_list
    f = file(tmp, 'w')
IOError: [Errno 13] Permission denied: '/home/git/gitosis/projects.list.30470.tmp'

Thanks in advance.

2
  • Which user are you running this command as? What is permission of /home/git/gitosis?
    – quanta
    Oct 2, 2011 at 16:20
  • @quanta, I'm running as root. The permission of /home/git/gitosis is rwxr-xr-x. Thanks.
    – aunghn
    Oct 2, 2011 at 16:27

2 Answers 2

1

You should remove /home/git/gitosis.

$ sudo rm -rf /home/git/gitosis

because you just moved gitosis files that has another permission.

0

Try to set owner of .ssh directory to git:

sudo chown -R git:git /home/git/.ssh

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .