40 lines
576 B
HCL
40 lines
576 B
HCL
job "test-nginx" {
|
|
datacenters = ["dc1"]
|
|
type = "service"
|
|
|
|
group "web" {
|
|
count = 1
|
|
|
|
network {
|
|
port "http" {
|
|
static = 8080
|
|
}
|
|
}
|
|
|
|
task "nginx" {
|
|
driver = "podman"
|
|
|
|
config {
|
|
image = "nginx:alpine"
|
|
ports = ["http"]
|
|
}
|
|
|
|
resources {
|
|
cpu = 100
|
|
memory = 128
|
|
}
|
|
|
|
service {
|
|
name = "nginx-test"
|
|
port = "http"
|
|
|
|
check {
|
|
type = "http"
|
|
path = "/"
|
|
interval = "10s"
|
|
timeout = "3s"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
} |