Sha256: a4c3773447f048d6f16f1d49d9425c678d8f109e8e5a153475bf72293f652c33
Contents?: true
Size: 1.22 KB
Versions: 1
Compression:
Stored size: 1.22 KB
Contents
require "thor" module Dogids class Cli < Thor no_commands do def ssh_production(vm_name = nil) case vm_name when "admin" ssh_address = get_config_url(vm_name) if ssh_address then puts "Running: `ssh -R 52698:localhost:52698 dogids@#{ssh_address}`" exec("ssh -R 52698:localhost:52698 dogids@#{ssh_address}") end when "db" ssh_address = get_config_url(vm_name) if ssh_address then puts "Running: `ssh -R 52698:localhost:52698 dogids@#{ssh_address}`" exec("ssh -R 52698:localhost:52698 dogids@#{ssh_address}") end when "web" ssh_address = get_config_url(vm_name) if ssh_address then puts "Running: `ssh -R 52698:localhost:52698 dogids@#{ssh_address}`" exec("ssh -R 52698:localhost:52698 dogids@#{ssh_address}") end when "worker" ssh_address = get_config_url(vm_name) if ssh_address then puts "Running: `ssh -R 52698:localhost:52698 dogids@#{ssh_address}`" exec("ssh -R 52698:localhost:52698 dogids@#{ssh_address}") end else ssh end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
dogids-cli-0.0.19 | lib/dogids/ssh/production.rb |