Reputation: 889
I'm building a service where users will send me their code via private git repos (similar to how users git push to Heroku). When a user signs up, I'd like to create repo that only they have access to via ssh key.
How would I set up a git server where users only have access to their individual repositories?
Creating SSH users for each user doesn't seem safe or scalable.
Upvotes: 2
Views: 59
Reputation: 1323145
You could consider still having each user public ssh keys, and identify them with said public key.
That is exactly what gitolite is doing, and if your Git repository hosting service install Gitolite, you will be able to manage a separate access for each user and their repos.
See more in my answer to "How do programs like gitolite work?".
Upvotes: 2