Re: gitweb on shared hosting
From: Martin Koegler <hidden>
Date: 2016-06-15 22:43:13
I don't know if this is possible or not, but I'm trying with no results. Is it possible to install gitweb on a shared hosting system, with no root access. Reading the INSTALL document reveals only information for configuration on build-time/install as root.
It is possible to install gitweb without root access, if you have:
1) A system to compile C programs for the hosting system
2) A directory to copy the binaries to on the hosting system. I would not make it accessible via the webserver.
3) A directory published by the webserver for static files
4) A directory which supports running perl cgis
If the requirements are met, do the following:
a) Extract git sources
b) Change in the Makefile PREFIX to the directories for the binaries
c) run make
d) If you compile on the hosting system, simple run make install. If
not, create a directory with the same patch as the binary directory on
the hosting system, run make install and copy the content of binary
directory to the hosting system (preserving the x-bits).
e) Copy gitweb/git-favicon.png, gitweb/git-logo.png and gitweb/gitweb.css onto your webserver.
f) Install gitweb/gitweb.cgi as perl CGI program. gitweb.cgi needs some configuration. You can
specify them either in a seperate configuration file or change the default settings in gitweb.cgi.
You should check the following options:
our $GIT = "/homes/user/bin/git"; # path to the git binary
our $projectroot = "/pub/git"; # path to the directoriy containing all git repositories
our @stylesheets = ("gitweb.css"); # URL to stylesheet
our $logo = "git-logo.png"; # URL to image
our $favicon = "git-favicon.png"; # URL to image
If the webserver has read (and execute for the binaries) rights on all
files (including the repositories), gitweb should work.
mfg Martin Kögler