Sha256: 568a3d686a6e6bcc093ec3067c874c480072db88a0995b244bd4f559829fb9ae

Contents?: true

Size: 830 Bytes

Versions: 10

Compression:

Stored size: 830 Bytes

Contents

class NOS < Oxidized::Model

  # Brocade Network Operating System

  prompt /^(?:\e\[..h)?[\w.-]+# $/
  comment  '! '

  cmd :all do |cfg|
    cfg.each_line.to_a[1..-2].join
  end

  cmd 'show version' do |cfg|
    comment cfg
  end

  cmd 'show inventory' do |cfg|
    comment cfg
  end

  cmd 'show license' do |cfg|
    comment cfg
  end

  cmd 'show chassis' do |cfg|
    comment cfg.each_line.reject { |line| line.match /Time/ or line.match /Update/ }.join
  end

  cfg 'show system' do |cfg|
    comment cfg.each_line.reject { |line| line.match /Time/ or line.match /speed/ }
  end

  cmd 'show running-config | nomore'

  cfg :telnet do
    username /^.* login: /
    password /^Password:/
  end

  cfg :telnet, :ssh do
    post_login 'terminal length 0'
    #post_login 'terminal width 0'
    pre_logout 'exit'
  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
oxidized-0.21.0 lib/oxidized/model/nos.rb
oxidized-0.20.0 lib/oxidized/model/nos.rb
oxidized-0.19.0 lib/oxidized/model/nos.rb
oxidized-0.18.0 lib/oxidized/model/nos.rb
oxidized-0.17.0 lib/oxidized/model/nos.rb
oxidized-0.16.3 lib/oxidized/model/nos.rb
oxidized-0.16.2 lib/oxidized/model/nos.rb
oxidized-0.16.1 lib/oxidized/model/nos.rb
oxidized-0.16.0 lib/oxidized/model/nos.rb
oxidized-0.15.0 lib/oxidized/model/nos.rb