/ndk-configtopus

Configtopus is an NDK app that demonstrates a wide variety of configuration components a NDK app can have

Primary LanguageGoBSD 3-Clause "New" or "Revised" LicenseBSD-3-Clause

Configtopus is an NDK app with a configuration tree that consists of various combinations of YANG data types. It is used to show how configuration changes made to the application tree are streamed back to the application and how to update application state for different configuration elements.

Quickstart

Clone and enter the repository:

git clone https://github.com/srl-labs/ndk-configtopus.git && \
cd ndk-configtopus

One-click deployment of the lab is available via run.sh script. It will build the app, deploy the lab and onboard the application to SR Linux:

./run.sh deploy-all

Enter the SR Linux CLI:

ssh configtopus

Once entered into the SR Linux CLI, you can find /configtopus context available that contains the application's configuration and operational data.

Experiment with the application config and observe how the application reacts to the changes. You can see the application logs in the ./log/srl/stdout/configtopus.log file available from the host machine.

Configuration tree

Configuration tree can be generated by running:

./run.sh conf-tree

The following output should be generated:

module: configtopus
  +--rw configtopus!
     +--rw action-leaf-node?           enumeration
     +--rw leaf-list-node*             string
     +--rw list-node* [name]
     |  +--rw name               string
     |  +--rw child-leaf-list*   string
     |  +--ro state?             uint64
     +--rw list-with-container* [value]
     |  +--rw value             string
     |  +--ro state?            uint64
     |  +--rw container-leaf
     |     +--rw leaf-uint?   uint64
     +--rw parent-list-node* [name]
     |  +--rw name          string
     |  +--rw child-list* [name]
     |     +--rw name     string
     |     +--ro state?   uint64
     +--rw container-with-leaf!
     |  +--rw leaf-decimal?                decimal64
     |  +--rw leaf-uint?                   uint64
     |  +--rw child-container-with-leaf
     |     +--rw child-container-with-leaf-list
     |        +--rw child-leaf-list*   string
     +--rw container-with-leaf-list
     |  +--rw child-leaf-list*   string
     +--rw container-with-list
        +--rw leaf-uint?    uint64
        +--rw child-list* [name]
           +--rw name     string
           +--ro state?   uint64

Shell autocompletions

To get bash autocompletions for ./run.sh functions:

source ./run.sh