small core configuration cleanup
This commit is contained in:
parent
6b43c00031
commit
3f1ff113ca
2 changed files with 7 additions and 15 deletions
|
@ -1,10 +1,3 @@
|
||||||
# Configuration file for CORE (core-gui, core-daemon)
|
|
||||||
|
|
||||||
### GUI configuration options ###
|
|
||||||
[core-gui]
|
|
||||||
# no options are presently defined; see the ~/.core preferences file
|
|
||||||
|
|
||||||
### core-daemon configuration options ###
|
|
||||||
[core-daemon]
|
[core-daemon]
|
||||||
listenaddr = localhost
|
listenaddr = localhost
|
||||||
port = 4038
|
port = 4038
|
||||||
|
@ -18,12 +11,11 @@ frr_sbin_search = "/usr/local/sbin /usr/sbin /usr/lib/frr"
|
||||||
# this may be a comma-separated list, and directory names should be unique
|
# this may be a comma-separated list, and directory names should be unique
|
||||||
# and not named 'services'
|
# and not named 'services'
|
||||||
#custom_services_dir = /home/username/.core/myservices
|
#custom_services_dir = /home/username/.core/myservices
|
||||||
#
|
|
||||||
# uncomment to establish a standalone control backchannel for accessing nodes
|
# uncomment to establish a standalone control backchannel for accessing nodes
|
||||||
# (overriden by the session option of the same name)
|
# (overriden by the session option of the same name)
|
||||||
#controlnet = 172.16.0.0/24
|
#controlnet = 172.16.0.0/24
|
||||||
#
|
|
||||||
#
|
|
||||||
# uncomment and edit to establish a distributed control backchannel
|
# uncomment and edit to establish a distributed control backchannel
|
||||||
#controlnet = core1:172.16.1.0/24 core2:172.16.2.0/24 core3:172.16.3.0/24 core4:172.16.4.0/24 core5:172.16.5.0/24
|
#controlnet = core1:172.16.1.0/24 core2:172.16.2.0/24 core3:172.16.3.0/24 core4:172.16.4.0/24 core5:172.16.5.0/24
|
||||||
|
|
||||||
|
|
|
@ -132,9 +132,9 @@ def get_merged_config(filename):
|
||||||
if not cfg.has_section(section):
|
if not cfg.has_section(section):
|
||||||
cfg.add_section(section)
|
cfg.add_section(section)
|
||||||
|
|
||||||
# merge command line with config file
|
# merge argparse with configparser
|
||||||
for opt in args.__dict__:
|
for opt in vars(args):
|
||||||
val = args.__dict__[opt]
|
val = getattr(args, opt)
|
||||||
if val is not None:
|
if val is not None:
|
||||||
cfg.set(section, opt, str(val))
|
cfg.set(section, opt, str(val))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue