About the course
Terraform is the industry-leading tool for managing infrastructure safely and efficiently through Infrastructure as Code (IaC). This 2-day, intensive hands-on course takes participants from Terraform fundamentals to advanced production-ready workflows.
We move beyond manual processes to explore how declarative configuration enables automation, consistency, and seamless team collaboration. You will progress from core CLI workflows - init, plan, and apply - to mastering complex state management, creating reusable modules, and securing sensitive data.
Through realistic labs, we tackle the challenges of multi-provider environments, configuration drift, and collaborative workflows, ensuring you leave with the practical skills to implement Terraform effectively in a professional devops environment.
Instructor-led online and in-house face-to-face options are available - as part of a wider customised training programme, or as a standalone workshop, on-site at your offices or at one of many flexible meeting spaces in the UK and around the World.
-
By the end of this course, attendees will be able to:
- Understand the concepts of Infrastructure as Code (IaC), the benefits of using Terraform, its architecture, installation, and core CLI workflow.
- Master the HashiCorp Configuration Language (HCL) to define infrastructure resources, data sources, providers, variables, locals, expressions, and functions.
- Understand and configure providers for various infrastructure platforms, including implementing secure authentication methods.
- Effectively manage Terraform state, including understanding state files, configuring local and remote backends (for multiple clouds and Terraform Cloud), implementing state locking, inspecting state, and importing existing infrastructure.
- Manage Terraform resources using advanced techniques like dependencies, iteration (count, for_each), and conditionals.
- Understand and effectively use Terraform Modules, including consuming existing modules from the Registry and creating your own reusable modules.
- Manage variables and their precedence, including automatic loading and usage in Terraform Cloud, and integrate with Secrets Management solutions to handle sensitive data securely within Terraform workflows.
- Understand and apply collaboration workflows with Terraform, using remote state backends and version control systems effectively.
- Utilise Terraform Workspaces for managing different environments or applications.
- Gain awareness of key features in Terraform Cloud/Enterprise, such as variable sets and policy as code (Sentinel).
- Understand concepts and apply basic techniques for testing Terraform code (static analysis, linting).
- Manage configuration drift and apply techniques for detection and handling.
- Implement Terraform best practices for code organisation, modularity, state management, and security.
- Debug and troubleshoot Terraform configurations and workflows effectively.
-
This 2-day intensive hands-on training course is designed for IT professionals who want to learn how to automate infrastructure provisioning and management using Terraform effectively in real-world, collaborative environments. It is ideal for:
Infrastructure Engineers
DevOps Engineers
Cloud Architects
Systems Administrators
Developers involved in infrastructure automation or cloud deployments
Anyone wanting to master Infrastructure as Code principles and practices using Terraform for production use cases.
-
Participants should have:
Familiarity with basic infrastructure concepts (servers, networking, storage).
Some understanding of cloud provider concepts (e.g., VPCs, VMs, Storage in AWS, Azure, or GCP – familiarity with at least one is beneficial).
Experience using a command-line interface (CLI).
No prior experience with Terraform is required.
We can customise the training to match your team's experience and needs - with more time and coverage of fundamentals such as working with the Command Line, or virtualisation / containerisation technologies.
-
This Terraform course is available for private / custom delivery for your team - as an in-house face-to-face workshop at your location of choice, or as online instructor-led training via MS Teams (or your own preferred platform).
Get in touch to find out how we can deliver tailored training which focuses on your project requirements and learning goals.
-
Introduction to Terraform and IaC
Understanding Infrastructure as Code (IaC) and its benefits.
Overview of Terraform architecture: Core, Providers, State.
Obtaining and installing Terraform.
The core Terraform CLI workflow: init, plan, apply, destroy.
Infrastructure lifecycle managed by Terraform.
Understanding the role of State in Terraform.
Lab: Installing Terraform and initialising a working directory.
Terraform Language Fundamentals (HCL)
Introduction to the HashiCorp Configuration Language (HCL).
Defining Resources: Creating infrastructure objects.
Using Data Sources: Querying existing infrastructure or external data.
Understanding and configuring Terraform Providers: Interacting with different APIs.
Provider Authentication: Secure methods for authenticating with cloud providers (e.g., environment variables, credentials files, IAM roles, service principals - conceptual overview and configuration).
Variables and outputs.
Complex variable types (lists, maps, objects).
Using Locals for reducing repetition.
Validation rules for input variables.
Interpolation syntax.
Expressions & Functions: Manipulating data within HCL.
Lab: Writing HCL configurations with resources, variables, and basic expressions.
Terraform State Management
Managing state files: Local state.
State file structure.
Backend configuration: Configuring remote state backends (e.g., S3, Azure Blob Storage, GCS, Terraform Cloud).
State locking: Preventing concurrent operations on state.
Inspecting state (terraform state show, terraform state list).
Modifying state (terraform state rm, terraform state mv - use with caution).
Importing existing resources into Terraform state (terraform import via the command line and Terraform code).
Lab: Configuring remote state, inspecting state, importing a resource.
Managing Resources: Dependencies and Iteration
Implicit and Explicit Dependencies between resources.
Using triggers for controlling resource updates.
Iterating on Resources:
Using count for simple iteration.
Using for_each for more complex iteration over maps or sets.
Implementing Conditional resources.
Lab: Managing resource dependencies, using count and for_each.
Modules: Using and Creating
Using Modules: Consuming modules from the Terraform Registry or local paths.
Module versioning
Creating your own reusable Modules:
Module structure and best practices.
Defining module input variables and output variables.
Lab: Using an existing module from the Registry, creating a simple reusable module.
Variables, Secrets, and Environments
Environment Variables: Dealing with parameters via the environment.
Environment variable options and precedence.
Automatic loading of variables (.tfvars files).
Using Variables in Terraform Cloud.
Key built-in environment variables (TF_LOG, TF_VAR_name...).
Secrets Management Integration:
Strategies for handling sensitive data (passwords, keys) without hardcoding.
Integrating Terraform with external Secrets Management solutions (e.g., HashiCorp Vault, cloud-specific secrets managers - conceptual overview).
Using sensitive variables and outputting sensitive data carefully.
Lab: Managing variables using multiple methods, exploring secrets handling concepts.
Collaboration Workflows and Workspaces
Collaboration Workflows with Remote State: Discussing best practices for team usage.
Terraform Workspaces: Using workspaces for managing different environments (dev, staging, prod) or applications.
Terraform Cloud/Enterprise Overview:
Workspaces in Terraform Cloud.
Variable Sets.
Policy as Code (Sentinel) overview.
Cost Estimation overview.
Lab: Using Terraform Workspaces.
Maintenance, Troubleshooting, and Best Practices
Workflows revisited: validate, fmt, taint, untaint, graph.
Debugging Terraform configurations and workflows.
Verbose Logging and log levels (TF_LOG).
Writing logs to files.
Understanding and interpreting Error messages.
Managing Drift: Detecting drift (terraform plan) and handling it (terraform refresh, terraform plan -refresh-only, terraform apply).
Testing Terraform Code (Introduction):
Static analysis and linting (tflint demo).
Security and compliance checking (checkov demo).
Introduction to integration testing concepts (e.g., Terratest - conceptual).
Terraform Best Practices:
Code organisation and structure.
Naming conventions.
Modularity and reusability.
State management strategies.
Security best practices (secrets, provider auth).
Lab: Debugging and troubleshooting exercises, running linting tools.
-
Terraform Documentation: The official and comprehensive documentation for Terraform.
Terraform Registry: The source for official and community providers and modules for various infrastructure platforms.
Terraform Cloud & Enterprise Documentation: Learn about features for teams and organisations using HashiCorp's managed service.
Provider Documentation (Examples):
TFLint: A widely used static analysis linter for Terraform.
Checkov: A static analysis tool to help secure cloud configurations and IaC.
HashiCorp Vault Documentation: Learn about a popular secrets management tool that integrates with Terraform.
Trusted by