{"thread":{"id":"13090","subject":"[PATCH] Document that WebDAV doesn't need git on the server, and works over SSL","startedAt":"2008-04-13T13:38:21Z","lastAt":"2008-04-13T13:38:21Z","messageCount":1,"participants":["Matthieu Moy"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"74255","messageId":"1208093901-19949-1-git-send-email-Matthieu.Moy@imag.fr","threadId":"13090","inReplyTo":null,"subject":"[PATCH] Document that WebDAV doesn't need git on the server, and works over SSL","fromName":"Matthieu Moy","fromEmail":"matthieu.moy@imag.fr","sentAt":"2008-04-13T13:38:21Z","receivedAt":"2008-04-13T13:38:21Z","isPatch":true,"sender":{"key":"git@matthieu-moy.fr","avatar":"https://avatars.githubusercontent.com/u/14709?v=4"},"body":"I managed to set up a Git repository on a preconfigured WebDAV server,\nand using HTTPS, without installing Git on it or changing the server\nconfiguration. This works through a proxy too. This patch reflects\nthis (it previously stated that Git was _necessary_ on the server,\nwhich isn't true). Also give a few hints to troubleshoting.\n\nSigned-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>\n---\n Documentation/howto/setup-git-server-over-http.txt |   46 ++++++++++++++------\n 1 files changed, 33 insertions(+), 13 deletions(-)\n\ndiff --git a/Documentation/howto/setup-git-server-over-http.txt b/Documentation/howto/setup-git-server-over-http.txt\nindex 8eadc20..a8da347 100644\n--- a/Documentation/howto/setup-git-server-over-http.txt\n+++ b/Documentation/howto/setup-git-server-over-http.txt\n@@ -1,5 +1,5 @@\n From: Rutger Nijlunsing <rutger@nospam.com>\n-Subject: Setting up a git repository which can be pushed into and pulled from over HTTP.\n+Subject: Setting up a git repository which can be pushed into and pulled from over HTTP(S).\n Date: Thu, 10 Aug 2006 22:00:26 +0200\n \n Since Apache is one of those packages people like to compile\n@@ -40,9 +40,13 @@ What's needed:\n \n - have permissions to chown a directory\n \n-- have git installed at the server _and_ client\n+- have git installed on the client, and\n \n-In effect, this probably means you're going to be root.\n+- either have git installed on the server or have a webdav client on\n+  the client.\n+\n+In effect, this means you're going to be root, or that you're using a\n+preconfigured WebDAV server.\n \n \n Step 1: setup a bare GIT repository\n@@ -50,9 +54,9 @@ Step 1: setup a bare GIT repository\n \n At the time of writing, git-http-push cannot remotely create a GIT\n repository. So we have to do that at the server side with git. Another\n-option would be to generate an empty repository at the client and copy\n-it to the server with WebDAV. But then you're probably the first to\n-try that out :)\n+option is to generate an empty bare repository at the client and copy\n+it to the server with a WebDAV client (which is the only option if Git\n+is not installed on the server).\n \n Create the directory under the DocumentRoot of the directories served\n by Apache. As an example we take /usr/local/apache2, but try \"grep\n@@ -169,7 +173,9 @@ On Debian:\n \n    Most tests should pass.\n \n-A command line tool to test WebDAV is cadaver.\n+A command line tool to test WebDAV is cadaver. If you prefer GUIs, for\n+example, konqueror can open WebDAV URLs as \"webdav://...\" or\n+\"webdavs://...\".\n \n If you're into Windows, from XP onwards Internet Explorer supports\n WebDAV. For this, do Internet Explorer -> Open Location ->\n@@ -179,8 +185,9 @@ http://<servername>/my-new-repo.git [x] Open as webfolder -> login .\n Step 3: setup the client\n ------------------------\n \n-Make sure that you have HTTP support, i.e. your git was built with curl.\n-The easiest way to check is to look for the executable 'git-http-push'.\n+Make sure that you have HTTP support, i.e. your git was built with\n+curl (version more recent than 7.10). The command 'git http-push' with\n+no argument should display a usage message.\n \n Then, add the following to your $HOME/.netrc (you can do without, but will be\n asked to input your password a _lot_ of times):\n@@ -197,10 +204,10 @@ instead of the server name.\n \n To check whether all is OK, do:\n \n-   curl --netrc --location -v http://<username>@<servername>/my-new-repo.git/\n-\n-...this should give a directory listing in HTML of /var/www/my-new-repo.git .\n+   curl --netrc --location -v http://<username>@<servername>/my-new-repo.git/HEAD\n \n+...this should give something like 'ref: refs/heads/master', which is\n+the content of the file HEAD on the server.\n \n Now, add the remote in your existing repository which contains the project\n you want to export:\n@@ -212,7 +219,6 @@ It is important to put the last '/'; Without it, the server will send\n a redirect which git-http-push does not (yet) understand, and git-http-push\n will repeat the request infinitely.\n \n-\n Step 4: make the initial push\n -----------------------------\n \n@@ -225,6 +231,15 @@ want to export) to repository called 'upload', which we previously\n defined with git-config.\n \n \n+Using a proxy:\n+--------------\n+\n+If you have to access the WebDAV server from behind an HTTP(S) proxy,\n+set the variable 'all_proxy' to 'http://proxy-host.com:port', or\n+'http://login-on-proxy:passwd-on-proxy@proxy-host.com:port'. See 'man\n+curl' for details.\n+\n+\n Troubleshooting:\n ----------------\n \n@@ -248,9 +263,14 @@ Reading /usr/local/apache2/logs/error_log is often helpful.\n \n   On Debian: Read /var/log/apache2/error.log instead.\n \n+If you access HTTPS locations, git may fail verifying the SSL\n+certificate (this is return code 60). Setting http.sslVerify=false can\n+help diagnosing the problem, but removes security checks.\n+\n \n Debian References: http://www.debian-administration.org/articles/285\n \n Authors\n   Johannes Schindelin <Johannes.Schindelin@gmx.de>\n   Rutger Nijlunsing <git@wingding.demon.nl>\n+  Matthieu Moy <Matthieu.Moy@imag.fr>\n-- \n1.5.5.rc0.25.g9d90.dirty\n"}]}