mina gem通过网关部署

时间:2013-03-08 13:28:52

标签: ruby deployment apache-mina

我正在使用mina gem进行部署。 我必须通过网关才能连接到我的服务器。 我知道capistrano能够实现它。

有没有人知道mina中的这个配置?

1 个答案:

答案 0 :(得分:1)

我不相信mina支持这个;当然,the source code并不表示这样的选择。我正在尝试使用set :ssh_options, ''语法,但是mina将-t附加到命令链的末尾,然后将其发送到错误的服务器。考虑更改mina代码,但将网关连接转移到本地ssh客户端本身可能更简单,并且可能使用set :forward_agent, true命令。要做到这一点,您可以在~/.ssh/config

中设置类似的内容
Host finaldestination.example.com
    ProxyCommand ssh user@gateway.example.com nc %h 22
    ForwardAgent yes

使用我的localhost作为网关进行测试似乎表明这是可行的。

希望这会有所帮助 - 尽管我意识到这并不是你所要求的。 :)