Simple Nomad Job - Nomad Typing CST Test
Loading…
Simple Nomad Job — Nomad Code
A simple Nomad job to run an Nginx container.
# nomad/demo/nginx.nomad
job "nginx" {
type = "service"
datacenters = ["dc1"]
group "web" {
task "nginx" {
driver = "docker"
config {
image = "nginx:1.21"
ports = ["http"]
}
resources {
cpu = 500
memory = 256
}
service {
name = "nginx"
port = "http"
}
}
network {
port "http" {
static = 8080
}
}
}
}Nomad Language Guide
HashiCorp Nomad is a highly available, distributed, and flexible workload orchestrator designed to deploy and manage containers, virtual machines, and standalone applications across any infrastructure.
Primary Use Cases
- ▸Orchestrating containerized and non-containerized workloads
- ▸Multi-region and multi-cloud application deployments
- ▸Batch processing, cron jobs, and service workloads
- ▸Integration with CI/CD pipelines for automated deployments
- ▸Scalable, resilient job scheduling across data centers
Notable Features
- ▸Single binary and minimal operational complexity
- ▸Supports Docker, OCI, Java, QEMU, and raw executables
- ▸Multi-region and multi-datacenter support
- ▸Service discovery via Consul integration
- ▸Declarative job specifications in HCL or JSON
Origin & Creator
Developed by HashiCorp, first released in 2015.
Industrial Note
Nomad is widely used in enterprises for running heterogeneous workloads with minimal operational overhead, especially where organizations require multi-cloud or hybrid-cloud orchestration without being locked into Kubernetes.