System

Module for working with the global system in EOS

This module provides an API for working with the global system settings in EOS. It provides the following class implementations:

  • System – Configures global system settings

System Attributes:
hostname (string): The hostname of the node as configured in the

running-configuration.

class pyeapi.api.system.System(node)[source]

Bases: pyeapi.api.abstract.Entity

The System class implements global config for the node

Global configuration settings include those thaat identify the node and provide node level configuration such as hostname

get()[source]

Returns the system configuration abstraction

The System resource returns the following:

  • hostname (str): The hostname value

Returns

Represents the node’s system configuration

Return type

dict

set_banner(banner_type, value=None, default=False, disable=False)[source]

Configures system banners

Parameters
  • banner_type (str) – banner to be changed (likely login or motd)

  • value (str) – value to set for the banner

  • default (bool) – Controls the use of the default keyword

  • disable (bool) – Controls the use of the no keyword`

Returns

True if the commands completed successfully otherwise False

Return type

bool

set_hostname(value=None, default=False, disable=False)[source]

Configures the global system hostname setting

EosVersion:

4.13.7M

Parameters
  • value (str) – The hostname value

  • default (bool) – Controls use of the default keyword

  • disable (bool) – Controls the use of the no keyword

Returns

True if the commands are completed successfully

Return type

bool

set_iprouting(value=None, default=False, disable=False)[source]

Configures the state of global ip routing

EosVersion:

4.13.7M

Parameters
  • value (bool) – True if ip routing should be enabled or False if ip routing should be disabled

  • default (bool) – Controls the use of the default keyword

  • disable (bool) – Controls the use of the no keyword

Returns

True if the commands completed successfully otherwise False

Return type

bool

pyeapi.api.system.instance(api)[source]

Returns an instance of System