From 03aeb0d8a0463151121e162edf7771747d8d174c Mon Sep 17 00:00:00 2001 From: Gregor MacDougall Date: Tue, 7 Feb 2017 10:27:57 -0500 Subject: [PATCH] Bump to 0.0.10 --- README.md | 8 ++++++++ lib/omc/stack_command.rb | 8 +++++--- lib/omc/version.rb | 2 +- 3 files changed, 14 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 2412158..6342fde 100644 --- a/README.md +++ b/README.md @@ -34,3 +34,11 @@ secret = "abcd1234" ``` omc help ``` + +Accepted ssh options: +``` +-R 3000:localhost:3001 # Forwards port 3000 on the remote host to port 3001 on the localhost +-A # Forward agent +``` + +Please the the ssh help for more detail. diff --git a/lib/omc/stack_command.rb b/lib/omc/stack_command.rb index 092e0d7..e12656c 100644 --- a/lib/omc/stack_command.rb +++ b/lib/omc/stack_command.rb @@ -101,9 +101,11 @@ def bastion def default_ssh_args [].tap do |args| - proxy_command = "ProxyCommand ssh -W %h:%p #{bastion.host}" - proxy_command += " -R #{@remote_forward}" if @remote_forward - args.push("-o", proxy_command) if bastion + if (bastion) + proxy_command = "ProxyCommand ssh -W %h:%p #{bastion.host}" + proxy_command += " -R #{@remote_forward}" if @remote_forward + args.push("-o", proxy_command) + end args.push("-A") if @forward_agent args.push("-R #{@remote_forward}") if @remote_forward end diff --git a/lib/omc/version.rb b/lib/omc/version.rb index 78fd699..1c7eaa5 100644 --- a/lib/omc/version.rb +++ b/lib/omc/version.rb @@ -1,3 +1,3 @@ module Omc - VERSION = '0.0.9' + VERSION = '0.0.10' end