This chapter covers
- Domain Name System and resource naming strategies
- Network creation with dynamic subnetting
- Using provisioners to break out of Terraform
- Local and external providers
- Validation with checks and conditions
- When not to use Terraform (and what to do instead)
The first two parts of the book covered the Terraform language itself and how to use Terraform in production. This knowledge should be more than enough to get you through most of the problems that you’re going to encounter. That being said, there are topics you may encounter that require some additional tools to work through.
This chapter is a bit different from previous ones. Rather than dive into a single topic, we explore a variety of useful patterns, niche providers, and advanced features of Terraform. Some of what we discuss, such as how to name your resources or the use of conditions and checks, may end up being tools that you use every day. Other parts of this chapter, such as the use of the external provider, will offer you tools that you likely won’t use every day but you will be grateful to have when you encounter a particularly thorny problem.