This post explores how to use the Nomad Terraform provider to control the lifecycle of a Nomad service.
Both HashiCorp Nomad and Terraform allow you to declaratively define infrastructure as code, but they serve different functions in the organization. Nomad schedules and monitors applications, making sure the application stays running and automatically reconciles any failure. Nomad supports rolling deploys to deliver safer convergence. Nomad also integrates with Consul for service discovery and Vault for secrets management. Terraform, on the other hand, is a lifecycle management and provisioning tool. It creates, updates, and destroys the underlying infrastructure which Nomad will use to run applications. But Terraform is much more than a infrastructure tool - Terraform can also manage the process of submitting, updating, and deleting Nomad applications, which will allows modeling your entire infrastructure as code.
The Nomad Terraform provider is perfect for continuous delivery for your applications, and in this post we will look at how these tools work seamlessly together to enable this workflow.
Nomad provider for HashiCorp Terraform to run jobs with HashiCorp Nomad.