hosts: localhost の下で command: ls -l を含む Ansible タスクは何をしますか?
hosts: localhost
command: ls -l
Controller 上で YAML ファイルを表示するだけです。
すべてのホストに Ansible をインストールします。
ls という名前の変数を定義するだけで、何も実行しません。
ls
Playbook の実行時に、選択された localhost の対象で ls -l を実行します。
ls -l