github.com/anth0d/nomad@v0.0.0-20221214183521-ae3a0a2cad06/e2e/disconnectedclients/input/lost_max_disconnect.nomad (about)

     1  job "lost_max_disconnect" {
     2  
     3    datacenters = ["dc1", "dc2"]
     4  
     5    group "group" {
     6  
     7      max_client_disconnect = "1h"
     8  
     9      count = 2
    10  
    11      constraint {
    12        attribute = "${attr.kernel.name}"
    13        value     = "linux"
    14      }
    15  
    16      constraint {
    17        operator = "distinct_hosts"
    18        value    = "true"
    19      }
    20  
    21      task "task" {
    22        driver = "docker"
    23  
    24        config {
    25          image   = "busybox:1"
    26          command = "httpd"
    27          args    = ["-v", "-f", "-p", "8001", "-h", "/var/www"]
    28        }
    29  
    30        resources {
    31          cpu    = 128
    32          memory = 128
    33        }
    34      }
    35    }
    36  
    37  }