mirror of
https://github.com/kemko/nomad.git
synced 2026-01-08 11:25:41 +03:00
* e2e: remove old oversubscription test * e2e: fixup and cleanup oversubscription test suite Fix and cleanup this old oversubscription test. * use t.Cleanup instead of defer in tests
37 lines
654 B
HCL
37 lines
654 B
HCL
# Copyright (c) HashiCorp, Inc.
|
|
# SPDX-License-Identifier: BUSL-1.1
|
|
|
|
job "oversubscription-docker" {
|
|
type = "batch"
|
|
|
|
constraint {
|
|
attribute = "${attr.kernel.name}"
|
|
operator = "="
|
|
value = "linux"
|
|
}
|
|
|
|
constraint {
|
|
attribute = "${attr.os.cgroups.version}"
|
|
operator = "="
|
|
value = "2"
|
|
}
|
|
|
|
group "group" {
|
|
task "task" {
|
|
driver = "docker"
|
|
|
|
config {
|
|
image = "busybox:1"
|
|
command = "/bin/sh"
|
|
args = ["-c", "cat /sys/fs/cgroup/memory.max; sleep infinity"]
|
|
}
|
|
|
|
resources {
|
|
cpu = 500
|
|
memory = 20
|
|
memory_max = 30
|
|
}
|
|
}
|
|
}
|
|
}
|