diff --git a/inventories/changes_10000_hosts.py b/inventories/changes_10000_hosts.py new file mode 100755 index 0000000000..4e2f7553db --- /dev/null +++ b/inventories/changes_10000_hosts.py @@ -0,0 +1,29 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +import json + +from datetime import datetime + + +def time_val(): + return datetime.utcnow().strftime('%Y_%m_%d_%H_%M_%S.%f') + + +host_names = [f'change_of_vars_{i}' for i in range(10000)] + +hostvars = {} +for host in host_names: + hostvars[host] = { + "static_key": "host_dynamic_{}".format(time_val()), + "dynamic_{}".format(time_val()): "host_static_value" + } + + +print(json.dumps({ + "_meta": { + "hostvars": hostvars + }, + "ungrouped": { + "hosts": host_names + } +})) diff --git a/inventories/changes_1000_hosts.py b/inventories/changes_1000_hosts.py new file mode 100755 index 0000000000..558a5c1d94 --- /dev/null +++ b/inventories/changes_1000_hosts.py @@ -0,0 +1,29 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +import json + +from datetime import datetime + + +def time_val(): + return datetime.utcnow().strftime('%Y_%m_%d_%H_%M_%S.%f') + + +host_names = [f'change_of_vars_{i}' for i in range(1000)] + +hostvars = {} +for host in host_names: + hostvars[host] = { + "static_key": "host_dynamic_{}".format(time_val()), + "dynamic_{}".format(time_val()): "host_static_value" + } + + +print(json.dumps({ + "_meta": { + "hostvars": hostvars + }, + "ungrouped": { + "hosts": host_names + } +})) diff --git a/inventories/changes_100_hosts.py b/inventories/changes_100_hosts.py new file mode 100755 index 0000000000..62d093fd9a --- /dev/null +++ b/inventories/changes_100_hosts.py @@ -0,0 +1,29 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +import json + +from datetime import datetime + + +def time_val(): + return datetime.utcnow().strftime('%Y_%m_%d_%H_%M_%S.%f') + + +host_names = [f'change_of_vars_{i}' for i in range(100)] + +hostvars = {} +for host in host_names: + hostvars[host] = { + "static_key": "host_dynamic_{}".format(time_val()), + "dynamic_{}".format(time_val()): "host_static_value" + } + + +print(json.dumps({ + "_meta": { + "hostvars": hostvars + }, + "ungrouped": { + "hosts": host_names + } +}))