feature: run specs on different port

Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
This commit is contained in:
Dominik Richter 2015-05-14 18:30:50 +02:00
parent 14eebb88e0
commit 483c12edc7

View file

@ -18,6 +18,7 @@ if ENV['SSH_SPEC']
c.host = ENV['TARGET_HOST'] c.host = ENV['TARGET_HOST']
options[:password] = ENV['LOGIN_PASSWORD'] || ENV['password'] options[:password] = ENV['LOGIN_PASSWORD'] || ENV['password']
options[:user] = ENV['LOGIN_USERNAME'] || ENV['user'] || Etc.getlogin options[:user] = ENV['LOGIN_USERNAME'] || ENV['user'] || Etc.getlogin
options[:port] = ( ENV['LOGIN_PORT'] || 22 ).to_i
if !ENV['LOGIN_KEY'].nil? if !ENV['LOGIN_KEY'].nil?
options[:keys] = [ENV['LOGIN_KEY']] options[:keys] = [ENV['LOGIN_KEY']]