Projects and Labs
Updated Jan 24, 2021 ·
Overview
This folder contains Ansible labs, project files, templates, inventories, roles, and supporting application examples.
The folders are grouped by purpose so each lab can be opened without searching through the full old notes tree.
Project Index
| Project | Purpose |
|---|---|
| Lab Setup Templates | CloudFormation templates used to create Ansible lab hosts. |
| Project 001 Ansible Basics | Core inventories, sample playbooks, two-tier app labs, and user labs. |
| Project 002 Ansible Roles | Role-based web server examples and vault playbook samples. |
| Project 003 Confluent Cloud | Playbooks for Confluent Cloud user and deployment tasks. |
| Project 004 Ecommerce LAMP | SQL, startup files, and walkthrough notes for the LAMP e-commerce project. |
| Project 005 Maven Sample | Maven sample application used by the Jenkins and deployment labs. |
| Lab 001 to Lab 038 | Individual Ansible lab walkthroughs and exercises. |
Lab Series
The lab walkthroughs are split into 38 individual folders so each exercise can be opened and reviewed on its own.
| Lab | Topic |
|---|---|
| Lab 001 | Playbook on Ping |
| Lab 002 | Playbook on Uname |
| Lab 003 | Copying gitconfig onto the Nodes |
| Lab 004 | Doing a dry-run using 'check' |
| Lab 005 | Playbook on sending .gitconfig |
| Lab 006 | Two-tier Design Part 1: Package Management |
| Lab 007 | Two-tier Design Part 2: Install services |
| Lab 008 | Two-tier Design Part 3: Upload application to Web Servers |
| Lab 009 | Two-tier Design Part 4: Configure the LoadBalancer |
| Lab 010 | Two-tier Design Part 5: Health Check Status |
| Lab 011 | Two-tier Design Part 6: Using Prompts |
| Lab 012 | Two-tier Design Part 6: Consolidate into One Playbook |
| Lab 013 | Two-tier Design: Using Include |
| Lab 014 | Two-tier Design: Using Variables |
| Lab 015 | Two-tier Design: Using Local Variables |
| Lab 016 | Two-tier Design: Using Registered Variables |
| Lab 017 | Two-tier Design: Using Ansible Roles |
| Lab 018 | Using Ansible Vault |
| Lab 019 | Creating Users |
| Lab 020 | Using host_vars and group_vars |
| Lab 021 | Creating Users with Passwords stored in Ansible Vault |
| Lab 022 | Creating Users with Conditionals and Variables |
| Lab 023 | Using Jinja2 Templates to Deploy motd |
| Lab 024 | Using Jinja2 Templates to Deploy /etc/hosts file |
| Lab 025 | Creating Users using Ansible Roles |
| Lab 026 | Installing gitconfig Role from Ansible Galaxy |
| Lab 027 | Installing CentOS-Apache Role from Ansible Galaxy |
| Lab 028 | Execute Script, Install httpd, and Edit a File |
| Lab 029 | Conditionals |
| Lab 030 | Loops |
| Lab 031 | Playbooks |
| Lab 032 | Deploying LAMP Server (TBC) |
| Lab 033 | Deploying a Web Application (TBC) |
| Lab 034 | Deploying Jenkins |
| Lab 035 | Installing Maven |
| Lab 036 | Install and Configure Tomcat as the Staging Environment |
| Lab 037 | Creating a Basic Ansible Playbook |
| Lab 038 | Deploying a LAMP Stack and Python Application |
Running Labs
Most Ansible examples assume you are inside the project folder that contains ansible.cfg.
ansible --list-hosts all
ansible-playbook playbooks/sample-ping.yml
warning
Review inventories and credentials before running any playbook. Several files were originally written for temporary lab hosts.