Problems in the setup and use of git server in Windows

Source: Internet
Author: User
Tags server website git client

recently, we found that the Code Version Management of the team is chaotic, and even has no awareness of version management, the source code of a project is sometimes found 2 or 3 times to find the correct version. In the past, I didn't have any special requirements on this. As long as it was easy for everyone to use, VSS, SVN, and TFs didn't matter. Considering offline work and later non-Microsoft development environments, we plan to use git to specifications : unify version management within the team. Speaking of git, GitHub is actually a good choice, but our source code and development documents are more or less related to many systems of the operator, and the risk of placing them on the Internet is still relatively high; based on this, I chose to build my own git server and store code, documents, version information, and other information on my Intranet server, which is the best thing.

our Intranet web servers are basically Windows Server systems. I checked some information and really felt that the configuration steps for setting up the GIT server under the win system were very embarrassing... The open-source ASP. net mvc program bonobo git server was used to build a git server for Dudu. Well, you can use it now. this open-source solution is now V1.1 and has added Chinese resource files.

I use a Windows Server 2003, IIS 6 + WebDAV + ASP. NET MVC 3. Basically, as long as you follow the step-by-step mode for deploying ASP. net mvc sites, there will be no major problems. SpecificThe installation steps and git client usage will not be discussed much. Dudu has already written a lot of details, and there is also a large tortoisegit usage tutorial on the Internet.Here I will only record some problems I encountered during configuration and usage. SiteAfter deployment, you must grant the write permission to the app_data folder because the SQLite database file, the global configuration information of the site, and the error log are all in this folder. After the bonobo. Git. server site runs properly, we can use the GIT client to clone, commit, pull, merge, push, and other versions of the Repository like GitHub.

The biggest problem encountered during this process is that the local version library cannot be submitted to the GIT server. There is no problem when the code is submitted to the local device, but when the code is pushed to the server, the following message is always displayed: Fatal: authentication failed:

I was wondering where the configuration or settings were wrong, because when I checked "anonymous" for the version library, I could submit it to the server without entering the user name and password, in this way, you cannot effectively manage and view version information through permissions and user names. Finally, I found a solution: in IIS, put the directory safe->Edit-> authentication method-> integrated Windows authentication is removed, and the entire upload process is unobstructed. Otherwise, we need to set every user added in the GIT server site to the window system user (http://forum.chodounsky.net/viewtopic.php? F = 11 & t = 92 ).

On the log-on server website, When you browse the uploaded files, the Error 404 is reported. In the local development environment, browsing and downloading files are normal. In this case, we only need to know the suffix defined by it.Bonobo. Git. ServerThe. browses and download files are respectively defined as. Browse and. Download suffixes, so they are in the main directory of IIS ->Configuration-> Add the corresponding extension:

During usage, I also found that if the version library name contains Chinese characters or decimal points, there will be problems (other special characters are not tested yet ). If it contains Chinese characters, it will fail to be submitted to the server. If it contains the decimal point, the information page for opening this database will be 404... These minor issues are also well handled. We can automatically convert the location of git libraries containing Chinese characters to HTML encoding, and automatically replace the decimal point or other special characters when adding or modifying a version library.

Now, we can use our own git server like GitHub.Bonobo. Git. ServerNow!

After two weeks of internal testing by the Team, the running status is stable.

You can share and discuss any good methods and problems during use.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.