[fix] role:mas:conf compose script
This commit is contained in:
parent
52862bb20f
commit
8e73310fae
1 changed files with 14 additions and 7 deletions
|
@ -103,16 +103,23 @@ def main():
|
||||||
data = {}
|
data = {}
|
||||||
### base
|
### base
|
||||||
if True:
|
if True:
|
||||||
data_ = _json.loads(file_read(args.base_file_path))
|
data = dict_merge(
|
||||||
data = dict_merge(data, data_)
|
data,
|
||||||
|
_json.loads(file_read(args.base_file_path))
|
||||||
|
)
|
||||||
### clients
|
### clients
|
||||||
if True:
|
if True:
|
||||||
for name in _os.listdir(args.clients_directory_path):
|
data = dict_merge(
|
||||||
data__ = _json.loads(file_read(_os.path.join(args.clients_directory_path, name)))
|
data,
|
||||||
data_ = {
|
{
|
||||||
"clients": data__
|
"clients": list(
|
||||||
|
map(
|
||||||
|
lambda name: _json.loads(file_read(_os.path.join(args.clients_directory_path, name))),
|
||||||
|
_os.listdir(args.clients_directory_path)
|
||||||
|
)
|
||||||
|
),
|
||||||
}
|
}
|
||||||
data = dict_merge(data, data_)
|
)
|
||||||
## output
|
## output
|
||||||
if True:
|
if True:
|
||||||
if (args.output_format == "json"):
|
if (args.output_format == "json"):
|
||||||
|
|
Loading…
Add table
Reference in a new issue