homelab/deconz.nomad

55 lines
957 B
Plaintext
Raw Normal View History

2022-05-09 06:50:29 +00:00
job "deconz" {
datacenters = ["homelab"]
type = "service"
meta {
forcedeploy = "0"
}
constraint {
attribute = "${attr.unique.hostname}"
value = "oscar"
}
group "deconz"{
network {
mode = "host"
port "http" {
to = 8124
static = 8124
}
port "ws" {}
}
2022-05-12 09:36:04 +00:00
task "deconz" {
2022-05-09 06:50:29 +00:00
driver = "docker"
service {
name = "deconz"
port = "http"
tags = [
]
}
config {
image = "deconzcommunity/deconz"
ports = ["http"]
privileged = true
volumes = [
"/mnt/diskstation/nomad/deconz:/opt/deCONZ",
"/dev/ttyACM0:/dev/ttyACM0"
]
}
env {
DECONZ_DEVICE = "/dev/ttyACM0"
TZ = "Europe/Paris"
DECONZ_WEB_PORT = "${NOMAD_PORT_http}"
DECONZ_WS_PORT = "${NOMAD_PORT_ws}"
}
2022-05-12 09:36:04 +00:00
resources {
memory = 75
}
2022-05-09 06:50:29 +00:00
}
}
}