Automate Packages and Repositories

WebAsha's inventory is ready in `~/ansible` (dev: node1, test: node2, prod: node3 + node4, webservers = prod). From now on nobody logs in to the nodes: every change is a playbook run from control. Start by installing the collections you need, then set up repositories and packages per environment.

Tasks

  1. Create ~/ansible/collections/requirements.yml that installs ansible.posix and community.general from http://utility/collections/ (the tarball URLs listed there), and install them into ~/ansible/collections.
  2. Write ~/ansible/repos.yml that defines a repository webasha-tools on all nodes: description WebAsha internal tools, baseurl http://utility/repo/tools, GPG checking on with gpgkey http://utility/repo/RPM-GPG-KEY-webasha, and disabled for now.
  3. Write ~/ansible/packages.yml: install tmux and zsh on the dev group only.
  4. Extend packages.yml with a second play that installs vsftpd on the prod group only (not dev or test). Use modules only, no command/shell.
  5. Write ~/ansible/pkgreport.yml: on the webservers, gather package facts and write /root/pkgreport.txt containing exactly one line httpd <version (the installed httpd version, e.g. httpd 2.4.63).