capistrano/capistrano — Issue #173: Cisco VPN (execute localy)
Author: drKreso
Created: 2012-03-03 13:59:39+00:00
State: open

I have a specific scenario where I am obliged by client to use Cisco VPN (government contract...). The problem with that is that Cisco cuts of the internet connection for the host computer.

def query_revision(revision) in (lib/capistrano/recipes/deploy/scm/git.rb)

Is trying to fetch revision ref from remote repository, and that is not working. I did a quick fix to get my deploy done, but I think this is worth generalizing.

Maybe to add a parameter to switch this behavior on.

:no_local_connectivity = true

If you think this would make sense I can clean up my code and send a pull request.

I did notice that before this was getting done completely locally but then it was added as a feature to git ls-remote.

There is even a code to do it localy, but for some reason I get the exception before and terminate.

# If sha is not found on remote, try expanding from local repository
command = scm('rev-parse --revs-only', revision)
newrev = yield(command).to_s.strip