summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/oxidized/model/ironware.rb11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/oxidized/model/ironware.rb b/lib/oxidized/model/ironware.rb
index 805e07b..c7fbeee 100644
--- a/lib/oxidized/model/ironware.rb
+++ b/lib/oxidized/model/ironware.rb
@@ -19,11 +19,6 @@ class IronWare < Oxidized::Model
cfg.each_line.to_a[1..-2].join
end
- cmd 'show running-config' do |cfg|
- cfg = cfg.each_line.to_a[3..-1].join
- cfg
- end
-
cmd 'show version' do |cfg|
cfg.gsub! /(^((.*)[Ss]ystem uptime(.*))$)/, '' #remove unwanted line system uptime
cfg.gsub! /[Uu]p\s?[Tt]ime is .*/,''
@@ -55,9 +50,15 @@ class IronWare < Oxidized::Model
end
cmd 'show module' do |cfg|
+ cfg.gsub! /^((Invalid input)|(Type \?)).*$/, '' # some ironware devices are fixed config
comment cfg
end
+ cmd 'show running-config' do |cfg|
+ cfg = cfg.each_line.to_a[3..-1].join
+ cfg
+ end
+
cfg :telnet do
username /^Username:/
password /^Password:/