• Stars
    star
    383
  • Rank 109,582 (Top 3 %)
  • Language
    Python
  • License
    GNU Lesser Genera...
  • Created almost 7 years ago
  • Updated 15 days ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

VyOS command definitions, scripts, and utilities

vyos-1x: VyOS command definitions, configuration scripts, and data

VyOS 1.1.x had its codebase split into way too many submodules for no good reason, which made it hard to navigate or write meaningful changelogs. As the code undergoes rewrite in the new style in VyOS 1.2.0+, we consolidate the rewritten code in this package.

If you just want to build a VyOS image, the repository you want is vyos-build. If you also want to contribute to VyOS, read on.

Package layout

data                   # Jinja2 templates
debian                 # Our package build system
interface-definitions  # Configuration interface (i.e. conf mode command) definitions
op-mode-definitions    # Operational command definitions
python                 # Programming library for accessing the config frontend/backend
schema                 # XML schema definition for conf mode and op mode commands
scripts                # Build-time scripts
smoketest              # Python Unittests for the CLI and system
src
    conf_mode/  # Configuration mode scripts
    op_mode/    # Operational mode scripts
    completion/ # Completion helpers
    validators/ # Value validators
    helpers/    # Misc helpers
    migration-scripts # Migration scripts
    tests/      # Unit tests

Interface/command definitions

Raw node.def files for the old backend are no longer written by hand or generated by custom scripts. They are all now produced from a unified XML format that supports a strict subset of the old backend features. In particular, it intentionally does not support embedded shell scripts, default values, and value "types", instead delegating those tasks to external scripts.

Configuration interface definitions must conform to the schema found in schema/interface_definition.rng and operational command definitions must conform to schema/op-mode-definition.rng. Schema checks are performed at build time, so a package with malformed interface definitions will not build.

Configuration scripts

The guidelines in a nutshell:

  • Use separate functions for retrieving configuration data, validating it, and generating taret config, see our documentation for the common structure
  • Use the get_config_dict() API as much as possible when retrieving values from the CLI
  • Use a template processor when the format is more complex than just one line (our standard is Jinja2)

Tests

Tests are executed at build time, you can also execute them by hand with:

pipenv install --dev
pipenv shell
make test

Runtime (Smoke Tests)

Runtime tests are executed by the CI system on a running VyOS instance inside QEMU. The testcases can be found inside the smoketest subdirectory which will be placed into the vyos-1x-smoketest package.

More Repositories

1

vyos-build

VyOS image build scripts
Python
935
star
2

vyos-documentation

VyOS readthedocs
Python
181
star
3

vyos-vm-images

Jinja
83
star
4

python-vyos-mgmt

A Python library for managing VyOS routers
Python
57
star
5

vyos-rolling-nightly-builds

Scheduled ISO nightly builds for current branch
40
star
6

vyos

VyOS 2.0 development repository
Python
39
star
7

vyatta-cfg-system

Vyatta system-level configuration templates/scripts
Shell
37
star
8

vyatta-cfg

Vyatta configuration system
C++
28
star
9

vyconf

Software appliance configuration framework
OCaml
25
star
10

ipaddrcheck

An IPv4 and IPv6 validation utility for use in scripts
C
20
star
11

vyatta-cfg-firewall

Configuration templates and scripts for the firewall subsystem.
Perl
13
star
12

vyos-utils-misc

Miscellaneous utilities and scripts for VyOS
Perl
12
star
13

vyatta-cfg-vpn

Vyatta VPN configuration
Perl
12
star
14

vyatta-cfg-quagga

Vyatta configuration templates and scripts for Quagga/FRR
Perl
10
star
15

vyatta-op

Vyatta bash completion for operational commands
Perl
10
star
16

vyatta-bash

Vyatta shell based on GNU Bourne Again SHell
C
10
star
17

vyos1x-config

OCaml library for parsing, manipulating, and exporting VyOS configs
OCaml
10
star
18

vyos-cloud-init

Python
10
star
19

conntrack-tools

conntrack-tools i.e. conntrack and conntrackd
C
9
star
20

vyatta-cluster

Vyatta configuration/operational commands for clustering
Perl
9
star
21

vyatta-wanloadbalance

vyatta wan load balance project
C++
9
star
22

libvyosconfig

Shared library for VyOS config files parsing and manipulation
OCaml
8
star
23

vyos-opennhrp

VyOS version of OpenNHRP
C
7
star
24

vyatta-nat

Vyatta configuration/operational commands for NAT
Perl
6
star
25

vyatta-config-mgmt

Vyatta config management config & op templates/scripts
Perl
6
star
26

libnss-mapuser

Package for mapping radius users to local users
C
5
star
27

vyatta-op-vpn

Vyatta VPN operations mechanism
Perl
5
star
28

vyos-ansible-old

Ansible Network Collection for VyOS
Python
4
star
29

vyos-integration-test

Shell
4
star
30

igmpproxy

IGMP Proxy CLI for VyOS/Vyatta
C
4
star
31

vyos-salt-minion

Python
4
star
32

community.vyos.net

VyOS community website
Sass
4
star
33

vyos-automation

HCL
4
star
34

live-boot

Roff
3
star
35

cve-checker

VyOS security vulnerability checker
Python
3
star
36

uncron

Simple job queue service
OCaml
3
star
37

vyos-strongswan

C
3
star
38

vyatta-cfg-qos

Configuration templates and scripts for QoS
Perl
3
star
39

net-snmp

Vyatta modifications to net-snmp
C
3
star
40

vyatta-op-qos

Operation templates and scripts for QoS
Perl
3
star
41

vyos-live-build

Shell
2
star
42

vyatta-op-quagga

Vyatta operational templates for Quagga router daemons
Perl
2
star
43

vyos-open-vm-tools

VyOS version of the open-vm-tools
C
2
star
44

vyos-utils

Auxilliary utilities for VyOS (validators, etc.)
OCaml
2
star
45

vyatta-biosdevname

Vyatta version of the biosdevname utility
Shell
2
star
46

vyatta-conntrack

Vyatta configuration/operational commands for Conntrack
Perl
2
star
47

vyatta-zone

Vyatta zone-policy package
Perl
2
star
48

pmacct

Vyatta version of pmacct
C
2
star
49

vyos-iptables

VyOS iptables package
C
2
star
50

vyos-xe-guest-utilities

xe-guest-utilities debianized for vyos
Go
2
star
51

vyos-world

VyOS metapackage
2
star
52

live-initramfs

Vyatta version of live-initramfs
Shell
2
star
53

vyatta-op-firewall

Operatation command templates and scripts for the firewall subsystem.
Perl
2
star
54

openvpn-duo-plugin

Python
1
star
55

infinitytier

Fork of ZeroTier
C++
1
star
56

libmnl

libmnl minimalistic netfilter library
Shell
1
star
57

initramfs-tools

Vyatta fork of initramfs-tools
Shell
1
star
58

linux-firmware

Linux firmware
Assembly
1
star
59

vyos-nhrp

VyOS nhrp cfg and op package
Perl
1
star
60

vyos-infrastructure

Various scripts and automations for VyOS infrastructure tasks
Python
1
star