DEV Community

Cover image for Setting Up Your Own Git Server

Setting Up Your Own Git Server

Erhan Kılıç on August 15, 2018

This post was first published on Setting Up Your Own Git Server Setting up your own git server is very useful. You can set up your own git server...
Collapse
 
mediumrowdy profile image
medium-rowdy

Setting up my own git server is something I've been meaning to do for several years, but never got around to it, thinking that it was a lot more complicated than this.

I could not believe how simple and easy it is!

Thank you for posting.

Collapse
 
tux0r profile image
tux0r

If you don't plan to let other people contribute to your repositories, git might be overkill.

Collapse
 
hoelzro profile image
Rob Hoelz

If Git would be overkill here, what would you propose as an alternative? I use Git on every project I work on, whether I'm the only one working on it or not, and it's saved my bacon more times than I can count!

Collapse
 
tux0r profile image
tux0r

Have you tried Darcs? It is perfect for small projects - and it won't cause problems when you try to merge multiple incompatible features.

Thread Thread
 
hoelzro profile image
Rob Hoelz

I have! I used to use it primarily a long time ago, but then I switched to using Git for my personal stuff when my job converted their repositories to Git - easier to keep one tool in my head! I still miss Darcs' UI - best VCS UI I've ever used.

Thread Thread
 
tux0r profile image
tux0r

You should try again! :-)

Not everything is a nail just because you have a hammer.

Collapse
 
lukad profile image
Luka Dornhecker • Edited

Or you could just install gitolite.

Collapse
 
foresthoffman profile image
Forest Hoffman
Collapse
 
arcaz21 profile image
Arcaz21 • Edited

Is there a way when I push my changes to my server and the server will create/update on another directory that I can access?

Collapse
 
quinncuatro profile image
Henry Quinn

Yeah. This could be considered part of a CI/CD pipeline. It usually needs some other tools set up on top of Git.

Collapse
 
erhankilic profile image
Erhan Kılıç

Yes you can do it and it's on article. You can edit post-recived and write bash code.

Collapse
 
gabrielbhh profile image
Gabriel Ben Harosh

Why not just use services like GitHub or Bitbucket?

Collapse
 
erhankilic profile image
Erhan Kılıç

Some people or companies wants to use their own git server. Some of them doesn't trust to GitHub, Bitbucket, Gitlab etc... I worked at some companies that uses their own git server. They customized everything for their purpose. I don't need to use my own git server but I learned when I work with these companies and I wanted to share my knowledge.

Collapse
 
erhankilic profile image
Erhan Kılıç

Yes but you must generate ssh key for your user. You can read detailed information on git book.