189k views
0 votes
Custom Ansible modules can be written in?

User Wodlo
by
8.5k points

1 Answer

2 votes

Final answer:

Custom Ansible modules are most commonly written in Python, although other languages like PowerShell, Ruby, and Bash can also be used depending on the system requirements and use cases.

Step-by-step explanation:

Custom Ansible modules can be written in a variety of programming languages. However, the most common language to write these modules is Python, due to its simplicity and the fact that Ansible itself is written in Python, which ensures better integration and compatibility. Other languages like PowerShell, Ruby, and Bash are also used, especially when interacting with systems where these languages are more native or when there are specific use cases or dependencies. Writing custom modules allows for the extension of Ansible's core functionality to perform tasks that are not covered by the pre-existing modules.

User Tony Tomov
by
8.2k points