The shift from Ansible Tower to the Ansible Automation Platform (AAP) represents a significant evolution in development, notably through the adoption of containerized job execution. Amidst these changes is Ansible Navigator, a new utility that consolidates multiple Ansible tools into one. This first article is just an introduction to Ansible Navigator; additional articles that explain different parts and usage will follow.
Installation For Red Hat subscribers, ensure you have the ansible-automation-platform-2....
In the microsoft.ad.group Ansible module, there is an option to add users and a different option to remove users. That means you would have to write two tasks, one to add and one to remove. As shown below:
--- - name: add or remove user from AD group hosts: all tasks: - name: Add members to the group, preserving existing membership microsoft.ad.group: name: "{{ groupname }}" scope: "{{ scope }}" members: add: "{{ usernames }}" when: user_option == 'add' - name: Remove members from the group, preserving existing membership microsoft....
HashiCorp’s Packer automates the creation of machine images across various platforms. I have recently been learning a bit about Packer, and in this post, I will show an example of using Packer to generate a Red Hat Enterprise Linux (RHEL) template on Proxmox. I still need to learn more of the Packer intricacies, and this article will be pretty high-level, but I hope it helps you at least start using Packer....
Ansible has many built-in lookups and filters to simplify tasks. Today, we’ll look at the password lookup and the random_string lookup. Both are useful when automating tasks involving generating random strings, like user passwords. Let’s compare the two and see why we would want to use one over the other.
The Password Lookup The password lookup generates random passwords; no surprise there.
Example of generating a random password:
--- - hosts: localhost vars: user_password: "{{ lookup('password', '....
An execution environment in Ansible refers to a container image that includes all the necessary dependencies, modules, and plugins to execute Ansible automation. It ensures consistent and reproducible execution of playbooks and roles by providing an environment with set configurations. By creating custom execution environments using ansible-builder, you can create reproducible environments tailored for the work you need to do. Ansible-builder makes maintaining and managing complex infrastructures easier while ensuring consistent and predictable outcomes....