WebFaction
Community site: login faq

I'm trying to setup a private git repo that I can push and pull from using http. I'm following the steps from the docs. When I try git remote add origin http://user@git.website.com/proj.git (where user is my htpasswd configured username, git.website.com is the git domain I setup on the webfaction panel, and proj.git is the name of my project) and then I try git push origin master I get this error after being prompted for my password:

XML error: not well-formed (invalid token) error: no DAV locking support on http://miko@git.audioquarium.com/ShockCollar.git/

I think it works fine when I push to the repo using ssh, just not http. I've set the http.receivepack to true on the git repo. Do I need to enable DAV locking support somehow?

asked 26 Jun '11, 18:13

Miko
1111
accept rate: 0%


The error is related to authentication, you should check the app logs for more info in ~/logs/frontend/

You may submit a support ticket and we can look directly.

permanent link

answered 26 Jun '11, 18:43

johns
5.4k412
accept rate: 23%

Thanks johns. All the git logs were empty, I've submitted a support ticket: HCX-215245

(26 Jun '11, 19:40) Miko

I've tried both of the below options and neither worked. I also created a ticket but the support tech was unable to re-create the problem. Any hints on this?

(17 Mar '13, 12:34) ccuilla

The ticket history shows we asked you some questions and were still working with you. Reply to the ticket and we will see what we can do.

(17 Mar '13, 20:50) johns

I ran into the same problem: I could no longer push to an existing git repo using "http://", I had to push using "ssh://".

I was able to get it working using the following blunt instrument:

. Create a new git application using the dashboard. . SSH to your account and mv the .htpasswd and *.git from the old git app to the new git app. . Change your git website(s) to point to the new git application from the old git application.

It now works. I don't know why. (Sorry for the formatting, but the ol/ul list options above the text box produce bazoo formatting).

permanent link

answered 04 Oct '11, 12:49

munch
1
accept rate: 0%

I had similar problems when trying to push to my webfaction git repository from a windows computer behind a proxy.

My git repository is public for read access and needs authentication for write.

I noticed some rejected requests in my server log, and modified the git application htaccess.

In the .htaccess file, look for the following lines:

RewriteBase /
RewriteCond %{REQUEST_URI} ^(.*?)/[a-zA-Z0-9_\-]+\.git/?.*$

And modify it as (added 3 lines in between):

RewriteBase /

RewriteCond %{REQUEST_URI} ^(.*?)/[a-zA-Z0-9_\-]+\.git/info/refs$
RewriteCond %{QUERY_STRING} service=git-receive-pack
RewriteRule ^([a-zA-Z0-9_\-]+\.git/info/refs)$ %1/auth/git.cgi/$1 [L]

RewriteCond %{REQUEST_URI} ^(.*?)/[a-zA-Z0-9_\-]+\.git/?.*$

How it works: When trying to push data, git checks if the git-receive-pack service exists, and the uses it. Without changes, this first check is done without authentication, and the git tries to do the push without requesting you for a login/password. With this change, the first check asks for authentication - git asks your login/password -, and the subsequent push is done with your credentials.

permanent link

answered 27 Feb '12, 07:35

Oleastre
1
accept rate: 0%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×111

question asked: 26 Jun '11, 18:13

question was seen: 15,124 times

last updated: 17 Mar '13, 20:50

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2020 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM