Configure a reverse proxy in apache

After ensuring the following modules are loaded in the httpd.conf

The following was added as virtual host:

Job Done!

To set up a git repository on a server

So because it’s on a server there is no working directory required – as a result we do a bare initialise in the folder that we want the repo to be in:

After that, to allow pushes to the server over http we need to run the following:

This will then work nicely with a virtual host in apache:

Also, make sure the user running apache has write permissions to the git repository folders.

Authentication

To add some basic authentication I have used the following 2 techniques:

To make an entire repository private:

To make all repositories public for read and private for write:

 Web UI

Finally, I have used gitlist to provide a web ui to my repositories – to achieve this I used the standard approach documented here

My final config looks like this: