git and "dumb protocols"

6 messages, 4 authors, 2016-08-11 · open the first message on its own page

git and "dumb protocols"

From: Matthieu Moy <hidden>
Date: 2016-08-11 20:45:03

Hi,

Is it possible with git to push to a server on which git is not
installed, and if so, how?

From the man page of git, sftp doesn't seem supported, and ssh://
complains about git-receive-pack not being installed on the server.

The man page documents a rsync:// protocol, but

$ git push rsync://some.location.com/
fatal: I don't handle protocol 'rsync'
$ 

What am I missing?

Thanks,

-- 

Re: git and "dumb protocols"

From: Johannes Schindelin <hidden>
Date: 2016-08-11 19:17:47

Hi,

On Thu, 2 Nov 2006, Matthieu Moy wrote:
Is it possible with git to push to a server on which git is not
installed, and if so, how?
See

http://www.kernel.org/git/gitweb.cgi?p=git/git.git;a=blob;h=ba191569af9501117322e1881160226a74867007;hb=html;f=howto/setup-git-server-over-http.txt

Hth,
Dscho

Re: git and "dumb protocols"

From: Petr Baudis <hidden>
Date: 2016-08-11 20:04:00

  Hi,

Dear diary, on Thu, Nov 02, 2006 at 11:36:07AM CET, I got a letter
where Matthieu Moy [off-list ref] said that...
Is it possible with git to push to a server on which git is not
installed, and if so, how?
  yes, you can push using HTTP DAV - just push to an HTTP URL; make sure
you have git-http-push compiled, it is sometimes not compiled because it
unfortunately adds dependencies on couple of more libraries.

  Beware that this is inherently not safe for anonymous push access,
since malicious client with write access can destroy the repository. You
will want to protect write access to the repository by .htaccess file.

  I think a patch that would add support for pushing over sftp or some
other dumb protocol would be welcome. One problem is with proper locking
of ref updates (not sure how well would sftp cope with that), another is
that you will need to do git-update-server-info's job on the server
side.

  If you already have SSH access to the server, why not compile Git
there and install it to your $HOME, though?

-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
#!/bin/perl -sp0777i<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<j]dsj
$/=unpack('H*',$_);$_=`echo 16dio\U$k"SK$/SM$n\EsN0p[lN*1

Re: git and "dumb protocols"

From: Johannes Schindelin <hidden>
Date: 2016-08-11 20:05:44

Hi,

On Thu, 2 Nov 2006, Petr Baudis wrote:
  If you already have SSH access to the server, why not compile Git
there and install it to your $HOME, though?
Could be a number of reasons:

- no compiler
- quota issues
- missing support for that particular platform
- time constraints
- etc

Happened to me.

Ciao,
Dscho

Re: git and "dumb protocols"

From: Andy Whitcroft <hidden>
Date: 2016-08-11 20:23:45

Matthieu Moy wrote:
Hi,

Is it possible with git to push to a server on which git is not
installed, and if so, how?
quoted
From the man page of git, sftp doesn't seem supported, and ssh://
complains about git-receive-pack not being installed on the server.

The man page documents a rsync:// protocol, but

$ git push rsync://some.location.com/
fatal: I don't handle protocol 'rsync'
$ 

What am I missing?
To push only makes sense when you have git installed at the receiving
end.  It is the interaction between the source and destination git
instances which renders the push an effective optimisation.

If you are using rsync, then you can just rsync the whole repository out
and what is out there is as valid as your own copy.  Of course a repack
will make the whole thing changed and you'll pay on the next rsync.

git is designed with this use model involved, you 'git
update-server-info' then rsync the repo in-toto out to your http server
and it can be fetch'ed from (all be it less efficiently) by another
client.  All without any requirement for anything other than passive
data delivery at the server end.  Great if you don't have shell access etc.

-apw

Re: git and "dumb protocols"

From: Petr Baudis <hidden>
Date: 2016-08-11 20:29:09

  Hi,

Dear diary, on Thu, Nov 02, 2006 at 11:57:16AM CET, I got a letter
where Johannes Schindelin [off-list ref] said that...
On Thu, 2 Nov 2006, Petr Baudis wrote:
quoted
  If you already have SSH access to the server, why not compile Git
there and install it to your $HOME, though?
Could be a number of reasons:

- no compiler
- quota issues
  good points.
- missing support for that particular platform
  If not with conjunction with the following ("- time constraints"), it
would be superb to add support for that particular platform. :^)

-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
#!/bin/perl -sp0777i<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<j]dsj
$/=unpack('H*',$_);$_=`echo 16dio\U$k"SK$/SM$n\EsN0p[lN*1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help