Friday, October 14, 2011

Using Subversion on Windows Server via HTTP

On my previous post, I mentioned about  our new development server which is hosted on windows server 2003 and serves via http. For our development environment subversion was chosen as a source control tool. Although our products mostly depends on microsoft platform and technologies, we didn't choose visual source safe. Actually, we've been using subversion as a source control tool on our local network. We were able to access the source by using standard file access protocol on windows OS environment.

I've never experienced in installing and configuring subversion by using http protocol on windows server. While I was browsing I came across VisualSVN Server whose standard edition is free. So I thought it's worth to try it. It's really easy installation process than I expected.

I'll explain my experience while installing and configuring new source control which is http-based subversion server.

Installation 
Repositories : This is used to define the place where your source code is stored.
Server Port : It specified the TCP/IP port which will be used by VisualSVN Server. Please make sure that port number shouldn't be used by any other application. If your port number you selected is used by any application, you can type different port number. Because of that we use teamviewer whose default port is 80, we needed to select different port number.
Authentication: In our case, we choose Subversion Authentication. So we created new accounts in Subversion and assign them to the projects in repositories. I explain how you can manage authentication on this post below.


After filling in all settings you can click Next and then wait for installation result. 

Now it's time to create new repositories.

Repository Layout
I chose the layout recommended by VisualSVN Server. In this layout, Repository contains project that contains three main folders which are : 
branches : it's temp folder to contain copy of trunk folder in order to test some functionalities of the project. It's like laboratory.
tags : it's used to store versions of officially deliverable applications.
trunk : it includes main development branch.

If you need more different strategies about repository layout  I recommend the link below:


Screenshot above shows an example of a repository layout. 
main and sandbox are repositories while application1, application2, library1, library2 represent projects.

VisualSVN Server Authorization
Creating users and assigning them to projects is really easy. Beside that you can create a group then put users inside the group. Finally you can assign group to a project. You are able to define read/write permission for each user or group.

To know more and detailed information about authorization you can visit the page written below :

If you did everything properly, you can reach your source control via http-based subversion server. 

http://dev.example.com:{port number}/svn/{your respository}

0 comments: