{"@id":"cedric-dumont.com"}

A developer's braindump

How to set up a git repository accessible through http on IIS

This post explain how to set up a shared git repository accessible through http using the Bonobo server (code available on github)


the best way to test it, is just by cloning the code on your local machine

git clone https://github.com/jakubgarfield/Bonobo-Git-Server

or

  • download the latest release and unzip it in your Project folder.
  • Open it with Visual studio and Build it (Restore nuget packages might help)
  • Set Bonobo-Git-Server project as startup project and hit F5.

after this, you can use BonoboServer

you can log in using user : admin, password : admin.

bonobo_login-bonobo

Click The Users Menu

bonobo_menu_user

Here you can create Users that will be able to connect or work on your repositories

bonobo_create_new_user

Click The Repositories Menu and create your repository, add the administrators or/and contributors

bonobo_create_new_repo

Use your repo like a normal git repo.
git clone http://localhost:6730/my-new-repo.git

Or if you already have a local repo

git remote add my-new-repo_name http://localhost:6730/my-new-repo.git

then

git push my-new-repo_name master
Install on IIS.

simply copy the Bonobo-Git-Server (or download a release from Bonobo site) in C:\inetpub\wwwroot and you are ready to go with http://My-Server-Name/Bonobo.Git.Server

(of course you can configure it like you would for any web application, I use wwroot for simplicity)


Note

I encountered the following error:

Could not load type ‘System.ServiceModel.Activation.HttpModule’ from assembly ‘System.ServiceModel, 
Version=3.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089′.

and solved it by changing in C:\Windows\System32\inetsrv\config\applicationHost.config the following line :

<br /><add name="ServiceModel" type="System.ServiceModel.Activation.HttpModule, System.ServiceModel, Version=3.0.0.0,
 Culture=neutral, PublicKeyToken=b77a5c561934e089" preCondition="managedHandler,runtimeVersionv2.0" />

To

<add name="ServiceModel" type="System.ServiceModel.Activation.HttpModule, System.ServiceModel, Version=3.0.0.0,
 Culture=neutral, PublicKeyToken=b77a5c561934e089" preCondition="managedHandler" />
Next: /2016/03/26/react-environment-with-webpack-enzyme-mocha-and-karma/
Prev: /2015/12/31/facebook-flux-pattern-implementation-in-net-c-startup/