Testing and Debugging Ansible Automation
Struggling to troubleshoot errors with Ansible automation? Got a playbook that fails, but have no idea why? In this course, you'll unlock effective tools and efficient methods for troubleshooting Ansible automation.
What you'll learn
It’s no secret that Ansible automation is easy to write and simple to execute. However, when errors crop up and playbooks start failing, troubleshooting what went wrong in your Ansible automation can become a daunting task. In this course, Testing and Debugging Ansible Automation, you’ll learn the tools and methods for effectively rooting out issues in your Ansible automation. First, you’ll explore how to use various command line options and tools to validate the integrity and functionality of your Ansible automation. Next, you’ll discover how to improve the error handling capabilities of your automation with a handful of built-in Ansible modules. Finally, you’ll learn how to use Ansible’s built-in debugger to walk through the execution of your Ansible automation step-by-step. When you’re finished with this course, you’ll have the skills and knowledge to efficiently troubleshoot failed Ansible automation, regardless of whether the root cause is faulty logic, improper user input, or a bug in an Ansible module.
Table of contents
- Course Introduction 4m
- Validate Syntax with --syntax-check 3m
- Target Specific Hosts and Groups with --limit 3m
- Run Specific Tasks, Plays, or Roles with --tags 3m
- View Proposed Changes with --check 4m
- View Proposed Changes with check_mode 4m
- Increase Verbosity with -v 3m
- Save Verbose Output with ANSIBLE_LOG_PATH 2m
- Enable Debug Logging with ANSIBLE_DEBUG 2m