Recent Changes - Search:

MineTest?

IRC?

Develop?

PC?

Windows?

Linux?

PmWiki

pmwiki.org

edit SideBar

GIT

This article describes how to create its own code repository on based Apache2 web server.

Ensure mod_cgi, mod_alias, and mod_env are enabled, set GIT_PROJECT_ROOT (or DocumentRoot) appropriately, and create a ScriptAlias to the CGI.

Create a tree of folders to house work files. These include repositories folders, log files and website's folder. We also need a tmp folder.

mkdir /opt
mkdir /opt/git
mkdir /opt/www
mkdir /opt/log
mkdir /opt/www/tmp

chown apache:apache /opt/git
chown apache:apache /opt/www
chown apache:apache /opt/log
chown apache:apache /opt/www/tmp
.  .  .  .
  SetEnv GIT_PROJECT_ROOT /var/www/git
  SetEnv GIT_HTTP_EXPORT_ALL
  ScriptAlias /git/ /usr/lib/git-core/git-http-backend/
  <LocationMatch ^/git/.*/git-receive-pack$>
    AuthType Basic
    AuthName "Git Access"
    AuthUserFile /var/www/git/.htpasswd
    Require valid-user
  </LocationMatch>
.  .  .  .


Edit - History - Print - Recent Changes - Search
Page last modified on June 07, 2023, at 10:28 AM