Insights into selecting a self-service UI framework for Ansible Automation
Wed, 03 Aug 2022 01:09:40 -0000|
Read Time: 0 minutes
Ansible is an astoundingly useful and convenient DevOps tool that helps streamline the process of managing remote hosts. However, it does have a learning curve and requires at least some technical knowledge to use efficiently given that it is a CLI (Command Line Interface) tool. Fortunately, there are several modern, feature-complete User Interface options for managing and running an Ansible instance on a remote server that can be controlled directly from a web browser. This, along with their open-source nature, makes the process of using Ansible and running playbooks much more intuitive and convenient; even for experienced team members that are familiar with using Ansible from the command line. This blog describes our evaluation of the most relevant aspects of each UI, including their features and accessibility.
AWX: The premiere open-source UI
Figure 1: AWX Dashboard
is the most well-known and feature complete UI for Ansible. It provides a sleek and intuitive interface that neatly organizes the configuration options by category and allows for the use of Role-Based Access Control. This gives users the option to regulate who can see or modify certain settings and files. Key amongst these are job templates, which serve as a set of parameters and definitions that allow the same job to be executed many times. Additionally, the built-in dashboard provides a visually pleasing yet extensive overview of past jobs as well as their outcome, along with other relevant information about the AWX configuration. Last, but certainly not least, AWX allows for secure and encrypted storage of credentials and vault passwords, allowing them to be shared between team members safely and effortlessly.
Ansible Semaphore: Easy to start, easy to use
Figure 2: Ansible Semaphore UI
Compared to AWX, Ansible Semaphore is more simplistic in every sense, with its straightforward installation process and streamlined UI coming at the cost of features that the other UI options we evaluated have. For example, Ansible Semaphore does not support high availability, meaning that it cannot automatically recover from component failure and can result in longer downtimes. However, this tool can easily be setup to pull ansible playbooks from GitHub, store credentials for GitHub/your machine, and run playbooks through a simple task template. Inside of a template you can specify hosts to run on (inventory), variables (environment), and extra command line arguments. That being said, Sempahore’s best feature is quite possibly its dashboard. Designed on Google’s Material UI, Ansible Semaphore’s dashboard is very easy to navigate and has a simplistic look to showcase the critical information for each run.
Rundeck Community Edition: More than just Ansible
Figure 3: Rundeck UI
gives users the basic functionality that is needed to execute playbooks inside a UI and, just like Ansible Semaphore, it is very easy to install and get up and running. Rundeck is a general automation tool so you can do more than just execute ansible playbooks, but the dashboard is not quite as easy to use as Ansible Semaphore and it is not as visually appealing. Some features of Rundeck CE include creating multi-step jobs, running shell commands, and executing local commands. While the community edition boasts many features beyond just running Ansible playbooks, the most desired features such as high availability and certified enterprise plugins are reserved for the enterprise or cloud editions.
Custom Coding the UI: Full Control
If none of the aforementioned solutions seem ideal to you, or they do not appropriately address your requirements, you always have the option of designing and creating your own UI solution. Doing so will grant you an appropriately scaled solution that meets all of your needs and requirements while also allowing you to express your creativity and originality. For example, if you want to offer some niche features to the UI like a “revert operation” that will undo a previously run playbook or displaying the completion percentage of a job that is in progress, then a custom UI could be your best option. However, this approach requires an immense amount of effort compared to the other options we discussed to develop and properly maintain a secure solution. One approach we investigated was to build a robust REST API running on an ansible-capable remote host for the backend services and a web frontend running on the same host. The two components of the application can then use HTTP requests to communicate and run and/or modify the pertinent files locally on the server.
Figure 4: UI Comparison Summary
Leveraging an Ansible UI is a great way to easily extend the functionalities and capabilities of Ansible to non-CLI experts by making server management and automation more accessible. Namely, it provides a less error prone execution and a more consumable way of seeing job progress and output for all users. Every option described above has its pros and cons, and it’s important to factor in the setup/installation process of each option. Incidentally, despite AWX being our top choice due to its maturity and feature set, its installation process is notoriously difficult. Because of this, our team decided to make our own guide describing what made the installation work for us. If you are interested in learning more about AWX’s setup process, feel free to check out the installation tutorial blog created by our team by clicking on the link right here!