Skip to content

Support configdir #27

@olofhagsand

Description

@olofhagsand

Clixon has two options that control configure files:
CLICON_CONFIGFILE
CLICON_CONFIGDIR
Pyapi only supports configfile, but it would be good to also support configdir. This is because options can be split into several config-files. In particular, the controller config options could be in a separate file from the main.
From clixon-config.yang:

       leaf CLICON_CONFIGDIR{
            type string;
            description
                "Location of directory of extra configuration files. 
                If not given, only main configfile is read.
                If given, and if the directory exists, all files in this directory will be loaded
                AFTER the main config file (CLICON_CONFIGFILE) in the following way:
                - leaf values are overwritten
                - leaf-list values are appended
                The files in this directory are loaded alphabetically.
                Only files ending with .xml are read
                Sub-structures, eg <autocli> are replaced with the latest (alphabetically)
                If the dir is given but does not exist will result in an error.
                You can override file setting with -E <dir> command-line option.
                Note that due to bootstraping this value is only meaningful in the main config file";

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions