diff options
author | Determinant <tederminant@gmail.com> | 2020-08-30 01:10:06 -0400 |
---|---|---|
committer | Determinant <tederminant@gmail.com> | 2020-08-30 01:10:06 -0400 |
commit | 2222565941bdf2516d1e3e5ae0f97f35dc023b0d (patch) | |
tree | 339aef90e5f2e195c39e3397851b6b905d5d24bf /scripts/deploy/gen_inventory.py | |
parent | d5bf357c8010bb1219d04ede14ce699b409e93c5 (diff) |
get deployment scripts to work
Diffstat (limited to 'scripts/deploy/gen_inventory.py')
-rw-r--r-- | scripts/deploy/gen_inventory.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/deploy/gen_inventory.py b/scripts/deploy/gen_inventory.py index 23af205..151bf45 100644 --- a/scripts/deploy/gen_inventory.py +++ b/scripts/deploy/gen_inventory.py @@ -31,4 +31,6 @@ if __name__ == "__main__": print("\n[clients]") for (i, ip) in enumerate(clients): - print("client{} ansible_host={} cid={}".format(i, ip, i)) + host_idx = host_idx_count.setdefault(pub_ip, 0) + host_idx_count[pub_ip] += 1 + print("client{} ansible_host={} host_idx={} cid={}".format(i, ip, host_idx, i)) |