ISPConfig shell CLI by Molnix
Following our very recent contribution of shell API examples to ISPConfig, the effort quickly grew into a full-blown command line tool for ISPConfig. I noticed the functionality we needed and the script we were building were a good fit for creating a proper CLI. With many other users in the community having expressed similar needs, I realized this was a good moment to contribute. The tool was merged to ISPConfig yesterday. We are currently asking for feedback on the tool’s current state and inviting more developers to contribute further functions.
This is the first release of the tool. It supports all methods already, and several smart functions’ equivalents are also available.
The key documentation is in the README.md in the tool directory. The command’s help function gives further detail on individual functions.
Since the CLI tool has been requested a few times in the community before, I hope to hear more about the use cases where it would have been handy in order to finalize the design to be as useful as possible.
The key questions are:
- How much validation would you expect from the tool? For example, when specifying a trailing zone and forgetting the trailing dot?
- When there are trade offs between features and ease-of-use, which way to go? For example, automatically updating a DNS A record when trying to add an existing one versus supporting multiple A records?
- Output format, pretty JSON (see dns_rr for example) versus simple lists (see dns_as for example)? Or selectable by switch? When using raw methods, the output is always JSON.
- Bash code review; naming conventions (now using several to avoid collisions), structure, subshell and return data improvements.
- How much use would there be for meta-functions which do not have method counterparts? See for example the current dns_cnames.
Feel free to also test the tool already and report any bugs. I am inviting more developers to join in the effort – adding functions is very fast and pleasing work. For example, the above mentioned dns_cnames function is a single, simple row of added code.
Join the discussion on the ISPConfig howtoforge developers forum.