CLI to create ucentral configuration files
Project description
ucentral cli
Create and modify valid ucentral-schema schemata.
Installation
pip install -e .
The latest ucentral.schema.json is required in the main folder.
Usage
Run CLI via ucentral
Supported commands:
add Add an anonymous obejct to the given configuration.
add-list Add the given value to a list option.
base64 Set <path> to base64 encoded content <filename>
del-list Delete element <value> from list at <path>
file Set <path> to content of <filename>
get Return value from <path>
load Load configuration from JSON at <filename>
schema-load Load JSON schema from <filename>
set Set <path> to <value>
show Show current configuration
write Store configuration as JSON at <filename>
Type help <command>
to see usage.
Examples
>> set uuid 123
>> set network.0.cfg.dhcp.leasetime 12h
>> set network.0.cfg.leases.0.hostname Apollo
>> add_list ntp.server ntp.example.org
>> add_list ntp.server ntp.example.com
>> show
{
"network": [
{
"cfg": {
"dhcp": {
"leasetime": "12h"
},
"leases": [
{
"hostname": "Apollo"
}
]
}
}
],
"ntp": {
"server": [
"ntp.example.org",
"ntp.example.com"
]
},
"uuid": 123
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ucentral-0.0.4.tar.gz
(3.5 kB
view details)
Built Distribution
File details
Details for the file ucentral-0.0.4.tar.gz
.
File metadata
- Download URL: ucentral-0.0.4.tar.gz
- Upload date:
- Size: 3.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6ad98497241bd9becd8ded491c3d058a1ad3582b949a9a217bca613792e275a1 |
|
MD5 | d9fbffe9537b6b43c555fb6b0f521a1d |
|
BLAKE2b-256 | c3cc15745191ef8586bef4255f73320c1a7097b5d665b816705d576a1868f032 |
File details
Details for the file ucentral-0.0.4-py3-none-any.whl
.
File metadata
- Download URL: ucentral-0.0.4-py3-none-any.whl
- Upload date:
- Size: 4.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.10.0 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7167bbf6db352a1ec0dd3abc068af72ea8116903c5e67bf94ca47857eac47090 |
|
MD5 | 375fc692059ba06abeb8bf303caf2ea7 |
|
BLAKE2b-256 | 490ee368d52fc044f121b0b993824050b166979bf9e119f5bc6f6e400c28eb6d |