Sha256: 174530985068721e7de08e9f7c3b9b2ad7808218030f61ef81140ee789496a56

Contents?: true

Size: 771 Bytes

Versions: 205

Compression:

Stored size: 771 Bytes

Contents

require 'puppet/node/facts'
require 'puppet/indirector/code'

class Puppet::Node::Facts::NetworkDevice < Puppet::Indirector::Code
  desc "Retrieve facts from a network device."

  def allow_remote_requests?
    false
  end

  # Look a device's facts up through the current device.
  def find(request)
    result = Puppet::Node::Facts.new(request.key, Puppet::Util::NetworkDevice.current.facts)

    result.add_local_facts
    result.sanitize
    result
  end

  def destroy(facts)
    raise Puppet::DevError, "You cannot destroy facts in the code store; it is only used for getting facts from a remote device"
  end

  def save(facts)
    raise Puppet::DevError, "You cannot save facts to the code store; it is only used for getting facts from a remote device"
  end
end

Version data entries

205 entries across 205 versions & 3 rubygems

Version Path
puppet-retrospec-1.8.0 vendor/pup410/lib/puppet/indirector/facts/network_device.rb
puppet-retrospec-1.7.0 vendor/pup410/lib/puppet/indirector/facts/network_device.rb
puppet-4.10.12 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.12-x86-mingw32 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.12-x64-mingw32 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.12-universal-darwin lib/puppet/indirector/facts/network_device.rb
puppet-4.10.11 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.11-x86-mingw32 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.11-x64-mingw32 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.11-universal-darwin lib/puppet/indirector/facts/network_device.rb
puppet-4.10.10 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.10-x86-mingw32 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.10-x64-mingw32 lib/puppet/indirector/facts/network_device.rb
puppet-4.10.10-universal-darwin lib/puppet/indirector/facts/network_device.rb
bolt-0.15.0 vendored/puppet/lib/puppet/indirector/facts/network_device.rb
bolt-0.14.0 vendored/puppet/lib/puppet/indirector/facts/network_device.rb
bolt-0.13.0 vendored/puppet/lib/puppet/indirector/facts/network_device.rb
puppet-retrospec-1.6.1 vendor/pup410/lib/puppet/indirector/facts/network_device.rb
bolt-0.12.0 vendored/puppet/lib/puppet/indirector/facts/network_device.rb
bolt-0.11.0 vendored/puppet/lib/puppet/indirector/facts/network_device.rb