diff options
author | Matthias Cramer <matthias.cramer@iway.ch> | 2017-06-16 11:52:47 +0200 |
---|---|---|
committer | Matthias Cramer <matthias.cramer@iway.ch> | 2017-06-16 11:52:47 +0200 |
commit | b7569965d1ec6112d0cd588ebd0b13a541bb6ef7 (patch) | |
tree | fbf410ebdfc268e55df73571fc85c426e8b25dbf /lib/oxidized/model/voss.rb | |
parent | bb06ac367daeed2f11682b8ef6e1182923570b42 (diff) | |
parent | dc425ce5bc3143cf4b8322602d7b7521aca37134 (diff) |
Merge branch 'master' of https://github.com/ytti/oxidized
Diffstat (limited to 'lib/oxidized/model/voss.rb')
-rw-r--r-- | lib/oxidized/model/voss.rb | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/lib/oxidized/model/voss.rb b/lib/oxidized/model/voss.rb new file mode 100644 index 0000000..599462a --- /dev/null +++ b/lib/oxidized/model/voss.rb @@ -0,0 +1,36 @@ +class Voss < Oxidized::Model + # Avaya VSP Operating System Software(VOSS) + # Created by danielcoxman@gmail.com + # May 15, 2017 + # This was tested on vsp4k and vsp8k + + comment '# ' + + prompt /^[^\s#>]+[#>]$/ + + # needed for proper formatting after post_login + cmd('') { |cfg| comment "#{cfg}\n" } + # get some general information about switch + cmd('show sys-info card') { |cfg| comment "#{cfg}\n" } + cmd('show sys-info fan') { |cfg| comment "#{cfg}\n" } + cmd('show sys-info power') { |cfg| comment "#{cfg}\n" } + + # more the config rather than doing a show run + cmd 'more config.cfg' do |cfg| + cfg + cfg.gsub! /^[^\s#>]+[#>]$/, '' + cfg.gsub! /^more config.cfg/, '# more config.cfg' + end + + cfg :telnet do + username /Login: $/ + password /Password: $/ + end + + cfg :telnet, :ssh do + pre_logout 'exit' + post_login 'enable' + post_login 'terminal more disable' + end + +end |