A Nomad group organizes related tasks inside a job. A job can contain many groups, and each group can contain many tasks or containers. Group-level settings coordinate those tasks, including instance count and network ports. section 9.2.5
One group, two application containers
The web job places Python and Node.js tasks in an apps group. Setting count = 1 requests one group instance, while group-level network mappings expose the applications on ports 8080 and 3000. section 9.2.5
Listing 9.8 Nomad job definition
job "a_unique_job_name" {
group "unique_group_per_job" {
task "unique_task_per_group" {
driver = "docker"
config {
image = "codingforentrepreneurs/rk8s-py"
}
}
}
}
Use the minimal HCL definition to see the nesting from job to group to Docker task. section 9.2.5
