RedHat Ansible (RH-294) journey under the guidance of Mr. Vimal Daga sir …

Nithish Kumar
4 min readOct 6, 2020

Hello Readers,
Today, I would like to share my journey of RedHat Ansible training under the mentor Mr. Vimal Daga sir …

Actually, this training s about 30 days, but he finished in 22 days from basic to very advance level… The way he teaching will fill the confidence with in us to do the complex things in a simple manner … And he proved that, “None of the technology is difficult to learn because it is created by human” ….

What I have learnt during these 22 days ~

Introduction to Ansible

  • Describe Ansible concepts and install Red Hat Ansible Engine.

Deploy Ansible

  • Configure Ansible to manage hosts and run ad hoc Ansible commands.

Implement playbooks

  • Write a simple Ansible playbook and run it to automate tasks on multiple managed hosts.

Manage variables and facts

  • Write playbooks that use variables to simplify management of the playbook and facts to Reference information about managed hosts.

Implement task control

  • Manage task control, handlers, and task errors in Ansible playbooks.

Deploy files to managed hosts

  • Deploy, manage, and adjust files on hosts managed by Ansible.

Manage large projects

  • Write playbooks that are optimized for larger, more complex projects.

Simplify playbooks with roles

  • Use Ansible roles to develop playbooks more quickly and to reuse Ansible code.

Troubleshoot Ansible

  • Troubleshoot playbooks and managed hosts.

Automate Linux administration tasks

  • Automate common Linux system administration tasks with Ansible.
  • Ansible for the management of managed hosts.

Deploy Ansible

  • Configure Ansible to manage hosts and run ad-hoc Ansible commands.

Implement playbooks

  • Write a simple Ansible Playbook and run it to automate tasks on multiple managed hosts
  • Packages: yum, become, with_items
  • Services: service
  • Files: copy, file, template, lineinfile
  • Application Modules: pip, mysql_db, mysql_user
  • Stack Status: wait_for, uri, register, fail, when

Manage variables and facts

  • Write playbooks that use variables to simplify management of the playbook and facts to reference information about managed hosts.

Implement task control

  • Manage task control, handlers, and task errors in Ansible Playbooks.

Deploy files to managed hosts

  • Deploy, manage, and adjust files on hosts managed by Ansible.

Manage large projects

  • Write playbooks that are optimized for larger, more complex projects.

Simplify playbooks with roles

  • Use Ansible roles to develop playbooks more quickly and to reuse Ansible code.
  • Converting to Roles: tasks, handlers, files, templates
  • Site.yml: include
  • Variables: facts, defaults, vars, with_dict, vars_files, group_vars, vault
  • Selective Removal: shell, register, with_items, when
  • External Roles & Galaxy

Troubleshoot, Testing & Validation

  • Troubleshoot playbooks and managed hosts.
  • Troubleshooting Ordering Problems
  • Jumping to Specific Tasks: list-tasks, step, start-at-task
  • Retrying Failed Hosts
  • Syntax-Check & Dry-Run: syntax-check, check
  • Debugging: debug
  • Testing Concepts

Automate Linux administration tasks

  • Automate common Linux system administration tasks with Ansible.

Advanced Execution

  • Removing Unnecessary Steps: gather_facts
  • Extracting Repetitive Tasks: cache_valid_time
  • Limiting Execution by Hosts & Tasks
  • Idempotence: changed_when, failed_when
  • Accelerated Mode and Pipelining

Here are the links for tasks which I have did in this training ~

Task 1:
Write an Ansible PlayBook that does the following operations in the managed nodes:
🔅 Configure Docker
🔅 Start and enable Docker services
🔅 Pull the httpd server image from the Docker Hub
🔅 Run the httpd container and expose it to the public
🔅 Copy the html code in /var/www/html directory and start the web server

Link: https://medium.com/@kumarnithish1999/how-to-integrate-ansible-with-docker-c47e4512510f?source=friends_link&sk=a580214f2b4bd50ce4e885e358825034

Task 2:
Statement :
Deploy Web Server on AWS through ANSIBLE!
🔅Provision EC2 instance through ansible.
🔅Retrieve the IP Address of instance using dynamic inventory concept.
🔅Configure the web server through ansible!
🔅Create role for webserver to customize the Instance and deploy the webpage to root directory.

Link: https://medium.com/@kumarnithish1999/configure-webserver-on-aws-cloud-using-automation-tool-called-ansible-cb1bba73c22a?source=friends_link&sk=ad28c91e1d1a1d03910d31e3bddb0a77

Task 3:
Statement:
Deploy a Load Balancer and multiple Web Servers on AWS instances through ANSIBLE!
🔅Provision EC2 instances through ansible.
🔅 Retrieve the IP Address of instances using the dynamic inventory concept.
🔅Configure the web servers through the ansible role.
🔅Configure the load balancer through the ansible role.
🔅The target nodes of the load balancer should auto-update as per the status of web servers.
Summary: One-Click Instance Launched, Web Servers provisioned and Load Balancer ready!

Link: https://medium.com/@kumarnithish1999/deploy-a-load-balancer-and-multiple-web-servers-on-aws-instances-through-ansible-92bf5649ad29?source=friends_link&sk=80075ee2976ce81d1e9a90c8ab2e89b8

In this training, for the first time I have been selected as volunteer to solve the queries asked by learner in slack channel as well as in whatsapp…

It’s a wonderful journey with Vimal Sir and Preeti Mam and Linux World India pvt …

--

--