Skip to content

Commit 3d5febc

Browse files
committed
Fixes geerlingguy#280: Ansible inventory dynamic Python script updates for Python 3 compatibility.
1 parent 284d7a4 commit 3d5febc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

dynamic-inventory/custom/inventory.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/env python
1+
#!/usr/bin/env python3
22

33
'''
44
Example custom dynamic inventory script for Ansible, in Python.
@@ -30,7 +30,7 @@ def __init__(self):
3030
else:
3131
self.inventory = self.empty_inventory()
3232

33-
print json.dumps(self.inventory);
33+
print(json.dumps(self.inventory));
3434

3535
# Example inventory for testing.
3636
def example_inventory(self):

0 commit comments

Comments
 (0)