morpheus-cli 0.9.5 → 0.9.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 434f161f0f0e7b31eb27d2930d1944e3bf7df388
4
- data.tar.gz: 1362db4a4894832d043898ced414b6e60c99a344
3
+ metadata.gz: 225abeec72be29393b66192db842883e5a6a0260
4
+ data.tar.gz: ddcee03ffae03cc3ade5f42d727bda5da4481e14
5
5
  SHA512:
6
- metadata.gz: d701a012d0e66263f2d5b29c8426ecf24f627f9628cf167aecd54a30bc4ecfc6de1ee8249c012e21b93f439408d5dac4a23178d04627fd5a933cccbce7ad9ca2
7
- data.tar.gz: 1415d32475a94b966ff1c1dd11d3cd79fd72d1fb37394d92dff020c85052a16b0073145058d3203817cb7ba8c1c18256b2b5a5b0e84c0fda2d99bca445e500a6
6
+ metadata.gz: 5396e4da45c594a30ead62e81349439edafff63faaeae9a1b11cd18d684973d313487c4a67193389c461d877ef6c4e2c0cd2d94a40aa3e04d2834e5dfcaa2bc7
7
+ data.tar.gz: 06b4067301d92403d0190c2290cbf02a99f1c4707a142c5162a508a3372417c060feb8ef0eafdfc25c3159e1c5c885688ad0b45e2329c96c769341d8e26ca0d4
@@ -40,7 +40,7 @@ class Morpheus::Cli::Hosts
40
40
 
41
41
  def handle(args)
42
42
  if args.empty?
43
- puts "\nUsage: morpheus hosts [list,add,remove,logs,start,stop,run-workflow,make-managed,upgrade-agent] [name]\n\n"
43
+ puts "\nUsage: morpheus hosts [list,add,remove,logs,start,stop,run-workflow,make-managed,upgrade-agent, server-types] [name]\n\n"
44
44
  exit 1
45
45
  end
46
46
 
@@ -64,7 +64,7 @@ class Morpheus::Cli::Hosts
64
64
  when 'server-types'
65
65
  server_types(args[1..-1])
66
66
  else
67
- puts "\nUsage: morpheus hosts [list,add,remove,logs,start,stop,run-workflow,make-managed,upgrade-agent] [name]\n\n"
67
+ puts "\nUsage: morpheus hosts [list,add,remove,logs,start,stop,run-workflow,make-managed,upgrade-agent, server-types] [name]\n\n"
68
68
  exit 127 #Command now foud exit code
69
69
  end
70
70
  end
@@ -113,6 +113,7 @@ class Morpheus::Cli::Remote
113
113
  end
114
114
  ::Morpheus::Cli::Remote.save_appliances(@appliances)
115
115
  list([])
116
+ @@appliance = nil
116
117
  end
117
118
 
118
119
  def set_active_appliance(name)
@@ -127,7 +128,7 @@ class Morpheus::Cli::Remote
127
128
 
128
129
  # Provides the current active appliance url information
129
130
  def self.active_appliance
130
- if !defined?(@@appliance)
131
+ if !defined?(@@appliance) || @@appliance.nil?
131
132
  @@appliance = load_appliance_file.select { |k,v| v[:active] == true}
132
133
  end
133
134
  return @@appliance.keys[0], @@appliance[@@appliance.keys[0]][:host]
@@ -38,6 +38,7 @@ class Morpheus::Cli::Shell
38
38
  optparse.parse(args)
39
39
 
40
40
  history = []
41
+ remote_handler = Morpheus::Cli::Remote.new()
41
42
  exit = false
42
43
  while !exit do
43
44
  print cyan,"morpheus > ",reset
@@ -73,7 +74,9 @@ class Morpheus::Cli::Shell
73
74
  argv.push "--nocolor"
74
75
  end
75
76
  #puts "cmd: #{argv.join(' ')}"
76
- if Morpheus::Cli::CliRegistry.has_command?(argv[0])
77
+ if argv[0] == 'remote'
78
+ remote_handler.handle(argv[1..-1])
79
+ elsif Morpheus::Cli::CliRegistry.has_command?(argv[0])
77
80
  Morpheus::Cli::CliRegistry.exec(argv[0], argv[1..-1])
78
81
  else
79
82
  puts "Unrecognized Command."
@@ -1,5 +1,5 @@
1
1
  module Morpheus
2
2
  module Cli
3
- VERSION = "0.9.5"
3
+ VERSION = "0.9.6"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: morpheus-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.5
4
+ version: 0.9.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Estes