Managed nodes, or hosts, are the devices managed by Ansible Automation Platform. To ensure a secure containerized setup, create a dedicated user on each node for Ansible Automation Platform to use when connecting and running tasks.
Procedure
- Log in to the host as the root user.
- Create a new user. Replace
<username> with the username you want, for example aap.
$ sudo adduser <username>
- Set a password for the new user. Replace
<username> with the username you created.
- Configure the user to run
sudo commands.
For a secure and maintainable installation, configure sudo privileges for the installation user in a dedicated file within the /etc/sudoers.d/ directory.
- Create a dedicated
sudoers file for the user:
$ sudo visudo -f /etc/sudoers.d/<username>
- Add the following line to the file, replacing
<username> with the username you created:
<username> ALL=(ALL) NOPASSWD: ALL
- Save and exit the file.