config-models

module
v0.9.7 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2022 License: Apache-2.0

README

config-models

This repository contains configuration model compiler and a few sample configuration models.

The config model compiler operates as a docker image that can be run on a volume where the model meta data and the desired model YANG files are contained as inputs. The compiler will produce a set of outputs from which a docker image can be built and can be started as a sidecar to onos-config. The outputs include generated Go code used for validating configurations, generated main and NB API that is used by the onos-config.

This structure allows configuration models to be hosted at arbitrary locations, while providing the neccessary toolchain conveniently contained wihin the compiler docker image.

Building model compiler image

To build the configuration model compiler, run:

make model-compiler-docker 

The above will compile and assemble the compiler docker image.

Sample models

The repository also include several sample configuration models located in the models directory and serving to demonstrate the structure of the configuration models.

  • devicesim-1.0.x
  • testdevice-1.0.x
  • testdevice-2.0.x

Building sample models

Building configuration models is easy. For example, to generate the artifacts for the devicesim-1.0.0 configuration model, run the following:

docker run -v $(pwd)/models/devicesim-1.0.x:/config-model onosproject/model-compiler:latest

Afterwards, to compile and assemble the configuration model docker image, simply run:

cd models/devicesim-1.0.x && make

Directories

Path Synopsis
cmd
modelplugin
aether-1.0.0 Module
aether-2.0.0 Module
aether-2.1.0 Module
aether-2.2.0 Module
aether-3.0.0 Module
aether-4.0.0 Module
e2node-1.0.0 Module
plproxy-1.0.0 Module
rbac-1.0.0 Module
ric-1.0.0 Module
stratum-1.0.0 Module
models
pkg

Jump to

Keyboard shortcuts

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