🎉 hyperglass 2.0 is here! This documentation is still in development, though.
Configuration
Devices File

Device Configuration Parameters

Each configured device may have the following parameters:

ParameterTypeDefault ValueDescription
nameStringDisplay name of the device.
descriptionStringDescription of the device, displayed as a subtle label.
avatarStringPath to an avatar/logo image for this site. Used when web.location_display_mode is set to gallery.
addressStringIPv4 address, IPv6 address, or hostname of the device.
groupStringGroup name, used to visually group devices in the UI.
portNumberTCP port on which to connect to the device.
platformStringDevice platform/OS. Must be a supported platform.
structured_outputBooleanTrueDisable structured output for a device that supports it.
directivesList of StringsEnable referenced directives configured in the directives config file.
driverStringnetmikoSpecify which driver to use for this device. Currently, only netmiko is supported.
driver_configMappingMapping/dict of options to pass to the connection driver.
attrsMappingMapping/dict of variables, as referenced in configured directives.
credentialMappingMapping/dict of a credential configuration.
httpMappingMapping/dict of HTTP client options, if this device is connected via HTTP.
proxyMappingMapping/dict of SSH proxy config to use for this device’s requests.

hyperglass ships with predefined directives (commands) for the following platforms:

  • SupportedArista EOS
  • SupportedBIRD
  • SupportedCisco IOS
  • SupportedCisco NX-OS
  • SupportedCisco IOS-XR
  • SupportedFRRouting
  • SupportedHuawei VRP
  • SupportedJuniper Junos
  • SupportedMikrotik
  • SupportedNokia SR OS
  • SupportedOpenBGPD
  • SupportedTNSR
  • SupportedVyOS

All built in directives require that the following attrs be defined on each device using the directive:

AttributeValue
source4IPv4 address used to source Ping and Traceroute commands.
source6IPv6 address used to source Ping and Traceroute commands.

Example

devices.yaml
devices:
    - name: New York, NY
      address: 192.0.2.1
      platform: cisco_ios
      attrs:
          source4: 192.0.2.1
          source6: "2001:db8::1"
⚠️

If you do not utilize IPv6 in your network, you’ll need to create your own directive that only has IPv4 commands.

Examples

Simple

devices.yaml
devices:
    - name: New York, NY
      address: 192.0.2.1
      platform: cisco_ios
      credential:
          username: you
          password: your password
    - name: San Francisco, CA
      address: 192.0.2.2
      platform: juniper
      credential:
          username: you
          password: your password

With Directives

In this example, an additional directive cisco-show-lldp-neighbors is added to the built-in directives.

devices.yaml
devices:
    - name: New York, NY
      address: 192.0.2.1
      platform: cisco_ios
      credential:
          username: you
          password: your password
      directives:
          - cisco-show-lldp-neighbors

Disable Built-in Directives

In this example, only the cisco-show-lldp-neighbors directive will be available. Built-in directives are disabled.

devices.yaml
devices:
    - name: New York, NY
      address: 192.0.2.1
      platform: cisco_ios
      credential:
          username: you
          password: your password
      directives:
          - builtin: false
          - cisco-show-lldp-neighbors

Enable Specifc Built-in Directives

In this example, only specified built-in directives are made available.

devices.yaml
devices:
    - name: New York, NY
      address: 192.0.2.1
      platform: cisco_ios
      credential:
          username: you
          password: your password
      directives:
          - builtin: [bgp_route, traceroute]