Class: Specinfra::HostInventory::SshdConfig
- Inherits:
-
Base
- Object
- Base
- Specinfra::HostInventory::SshdConfig
- Defined in:
- lib/pullmatic/resource/etc.rb
Instance Method Summary collapse
Instance Method Details
#get ⇒ Object
41 42 43 44 45 46 47 48 49 |
# File 'lib/pullmatic/resource/etc.rb', line 41 def get cmd = backend.command.get(:get_inventory_sshd_config) ret = backend.run_command(cmd) if ret.exit_status == 0 parse(ret.stdout) else nil end end |
#parse(ret) ⇒ Object
51 52 53 54 55 56 57 |
# File 'lib/pullmatic/resource/etc.rb', line 51 def parse(ret) entries = [] ret.split("\n").each do |l| entries << l if l =~ /^[^#]/ end entries end |