nokia

package
v0.0.0-...-45f8ed2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 15, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrIncompatibleCliConn raised when an invalid scrapligo cli transport type is found.
	ErrIncompatibleCliConn = errors.New("incompatible cli connection in use")
)

Functions

func New

func New(nodeImpl *node.Impl) (node.Node, error)

Types

type Node

type Node struct {
	*node.Impl

	ControllerClient ctrlclient.Client
	// contains filtered or unexported fields
}

func (*Node) ConfigPush

func (n *Node) ConfigPush(ctx context.Context, r io.Reader) error

ConfigPush pushes config lines provided in r using scrapligo SendConfig

func (*Node) Create

func (n *Node) Create(ctx context.Context) error

Create creates a Nokia SR Linux node by interfacing with srl-labs/srl-controller

func (*Node) CreateConfig

func (n *Node) CreateConfig(ctx context.Context) (*corev1.Volume, error)

func (*Node) Delete

func (n *Node) Delete(ctx context.Context) error

func (*Node) GenerateSelfSigned

func (n *Node) GenerateSelfSigned(ctx context.Context) error

GenerateSelfSigned generates a self-signed TLS certificate using SR Linux tools command and creates an enclosing server profile.

func (*Node) ResetCfg

func (n *Node) ResetCfg(ctx context.Context) error

ResetCfg resets the config of the node by reverting to a named checkpoint "initial" that is created by srl-controller for each node.

func (*Node) SpawnCLIConn

func (n *Node) SpawnCLIConn() error

SpawnCLIConn spawns a CLI connection towards a Network OS using `kubectl exec` terminal and ensures CLI is ready to accept inputs. scrapligo options can be provided to this function for a caller to modify scrapligo platform. For example, mock transport can be set via options

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL