module PuppetX::NetDev::EosApi::CommonMethods
CommonMethods
implements common methods, such as returning the running config. This separation makes it easier to provide documentation and introspect where methods come from given an api instance.
Public Instance Methods
running_config()
click to toggle source
@api private
@return [String] the text of the running configuration
# File lib/puppet_x/net_dev/eos_api/common_methods.rb, line 17 def running_config prefix = %w(enable) cmd = 'show running-config' msg = 'show running configuration' result = eapi_action([*prefix, cmd], msg, format: 'text') result.last['output'] end