Re: Pushing to a remote repo from a remote repo?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Apr 14, 2012 at 07:16:36PM -0400, Brian Cardarella wrote:

> Yes, I assumed the bits need to come through my system. I want to
> avoid cloning, pushing, then removing the repo. But it seems that is
> not possible. Thank you.

This isn't really a git problem, but rather a network proxying problem.
You could solve it with netcat and ssh like:

  # forward port 5001 on our local box to ssh on the "source" box
  nc -lp 5001 -c 'nc $source 22' &

  # forward port 5001 on the destination box to our local forward,
  # and then start the clone
  ssh -R 5001:localhost:5001 $dest \
    'git clone ssh://localhost:5001/path/to/repo'

If the repository is accessible by http, then you can easily tweak it to
forward to port 80. If, for some reason, you prefer push rather than
fetch, you can create the tunnels in the reverse direction.

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]