Provisioning a virtual machine using the kvm_libvirt module
One thing that you may or may not include is a setting that defines how SSH is used to connect to machines Ansible is going to configure. Before we do that, we need to spend a bit of time talking about security and Ansible. Like almost all things related to Linux (or *nix
in general), Ansible is not an integrated system, instead relying on different services that already exist. To connect to systems it manages and to execute commands, Ansible relies on SSH
(in Linux) or other systems such as WinRM or PowerShell on Windows. We are going to focus on Linux here, but remember that quite a bit of information about Ansible is completely system-independent.
SSH
is a simple but extremely robust protocol that allows us to transfer data (Secure FTP, SFTP, and so on) and execute commands (SSH
) on remote hosts through a secure channel. Ansible uses SSH directly by connecting and then executing commands and transferring files. This...