-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.nomad
50 lines (44 loc) · 943 Bytes
/
example.nomad
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
job "logs" {
datacenters = ["dc1"]
type = "system"
group "logs" {
restart {
mode = "delay"
interval = "1m"
}
task "logs" {
driver = "docker"
config {
image = "roomsh/nomad-journald-logs:latest"
mounts = [
{
type = "bind",
source = "/var/log/journal"
target = "/var/log/journal"
},
{
type = "bind",
source = "/etc/machine-id"
target = "/etc/machine-id"
},
{
type = "bind",
source = "/opt/nomad/alloc"
target = "/allocs"
}
]
logging {
type = "journald"
config {
mode = "non-blocking"
max-buffer-size = "16m"
}
}
}
resources {
cpu = 100
memory = 128
}
}
}
}