2019-08-14 14:23:33 +00:00
|
|
|
job "example" {
|
|
|
|
datacenters = ["dc1"]
|
|
|
|
|
|
|
|
group "cache" {
|
2020-09-16 15:06:19 +00:00
|
|
|
network {
|
|
|
|
port "db" {
|
|
|
|
to = 6379
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2019-08-14 14:23:33 +00:00
|
|
|
task "redis" {
|
|
|
|
driver = "docker"
|
|
|
|
|
|
|
|
config {
|
2021-10-06 19:30:23 +00:00
|
|
|
image = "redis:3.2"
|
|
|
|
ports = ["db"]
|
|
|
|
auth_soft_fail = true
|
2019-08-14 14:23:33 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
resources {
|
|
|
|
cpu = 500
|
|
|
|
memory = 256
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|