Git server setup under Windows platform

Source: Internet
Author: User

First step: download java,:http://www.java.com/zh_cn/

Step Two: install Java. The installation steps are no longer detailed.

Step Three: Configure the Java environment variables.

Right-click "Computer" + "Properties" + "Advanced system Settings" + "advanced" + "environment variables" = "System Variables".

    1. New:

Variable name: java_home

Variable Value: D:\Program Files (x86) \java\jdk1.6.0_21 "specifically according to your own installation path, my is installed on the D-drive"

2. NEW:

Variable name: CLASSPATH

Variable value:.; %java_home%/lib/dt.jar;%java_home%/lib/tools.jar

3. Add: Locate the path variable and select Edit. Add the%java_home%/bin;%java_home%/jre/bin to the end of the variable value.

Fourth Step: Verify that Java is installed successfully.

Open the Command window and enter cmd = = OK.

In the Command window, enter the Java command: Javac, enter, if the following information appears, the installation is successful.

Fifth step: download gitblit.:http://www.gitblit.com/

Sixth step: unzip the downloaded compressed package, without installation.

Seventh Step: Create a folder to store your data.

Eighth Step: Configure the Gitblit.properties file.

    1. Locate the Gitblit.properties file under the data file in the Git directory, and Notepad opens.

2. Locate the Git.repositoriesfolder (database path) and assign the seventh step to create a good file directory.

3. Locate the Server.httpport, set the port number of the HTTP protocol

4. Locate the Server.httpbindinterface and set the IP address of the server. Set up your server IP here.

5. Locate server.httpsbindinterface, set as localhost

6. Save and close the file.

nineth Step: Run the gitblit.cmd batch file.

    1. Locate the Gitblit.cmd file in the Bitblit directory, and double-click it.

2. The running result is as follows, the operation is successful.

Tenth step: Open in the browser, now you can use Gitblit, the default user name password is: admin.

11th Step: Set the Windows Service mode to start Gitblit.

    1. Under the Gitblit directory, locate the Installservice.cmd file.

2. Open with Notepad.

3. Modify ARCH

32-bit system: SET arch=x86

64-bit system: SET ARCH=AMD64

4. Add CD to program directory

SET cd=d:\git\gitblit-1.6.0 (your actual directory)

5. Modify the startup parameters in the Startparams, and empty it.

6. Save and close the file.

12th step: start Gitblit in Windows service mode.

    1. Double-click the Installservice.cmd file under the Gitblit directory (run as Administrator).

2. Under the service management of the server, you can see the existing Gitblit service.

3. When used normally, it is possible to keep the service up and running.

The above is the entire contents of the GITV server configured under the Windows platform.

By--http://www.cnblogs.com/ucos/p/3924720.html

++++++++++++++++++++++++++++++++++++++++++++++++++++

2. Gitblit Service failed to start

Gitblit decompression, the command line before running Installservice.cmd, need to modify the parameters inside, the arch modified x86, the default is AMD64, my machine is the Windows Pro 64-bit version, the JDK is also 64-bit, However, the default AMD64 cannot be started and the following error occurred at startup:

[2015-12-01 21:58:31]  [INFO] Commons Daemon Procrun (1.0.10.0 32-bit) started

[2015-12-01 21:58:32]  [INFO] Running ' Gitblit ' Service ...

[2015-12-01 21:58:32]  [INFO] Starting service ...

[2015-12-01 21:58:32] [ERROR] Failed creating Java

[2015-12-01 21:58:32] [ERROR] Servicestart returned 1

[2015-12-01 21:58:32]  [INFO] Run Service finished.

[2015-12-01 21:58:32]  [INFO] Commons Daemon Procrun finished

The modified installservice.cmd content is:


After modifying, the administrator rights in the CMD window to execute installservice.cmd, do not double-click, double-click seemingly no response.

Under Windows 8 and 10, open admin mode cmd by: Ctrl + X, select Command Prompt (admin).

After the command line is started, the Gitblit service can be seen inside the Windows service, and then run Gitblitw.exe with administrator privileges. I am here to have started well after:

Then modify the Java version to 32-bit jvm.dll. This will enable the service to start, click on the Start button. You can start automatically every time you start


The JVM used in the Gitblit is the client mode, and the benefit is that the speed is better than the stability, and if the user has a lot of access and stability first, then the JVM with server mode is used:\java\jdk1.7.0_67\jre\bin\server\jvm.dll

by--http://aigo.iteye.com/blog/2260957

Git server setup under Windows platform

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.