openHAB — a vendor- and technology-agnostic open-source home automation platform (a Home Assistant alternative) that integrates 300+ device bindings. Deployed as a single host-networked Nomad service.
Needs nomad-pack on PATH. The script only adds the nomploy registry and runs this pack.
Source ↗ Project ↗ ★ 3.4k ⚑ Report an issue
Save as values.hcl, edit, then run:
# The name of the Nomad job.
job_name = "openhab"
# The Nomad namespace to deploy into.
namespace = "default"
# The datacenters to deploy to.
datacenters = ["*"]
# The openHAB container image. Pin a tag in production.
image = "openhab/openhab:latest"
# Host port for the openHAB web UI (HTTP).
port = 8080
# Host port for the openHAB web UI (HTTPS).
https_port = 8443
# Timezone for the container (e.g. Europe/Bratislava).
timezone = "UTC"
# Named volume for openHAB configuration (/openhab/conf).
conf_volume = "openhab_conf"
# Named volume for openHAB userdata / database (/openhab/userdata).
userdata_volume = "openhab_userdata"
# Named volume for manually installed add-ons (/openhab/addons).
addons_volume = "openhab_addons"
# Placement constraints. On a nomploy cluster: attribute = "$${meta.nomploy_control_plane}", operator = "=", value = "true". Pin to the node on your device LAN.
constraints = []
# The task resources.
resources = {
cpu = 1000
memory = 1024
}
| Name | Type | Default | Description |
|---|---|---|---|
| job_name | string | "openhab" | The name of the Nomad job. |
| namespace | string | "default" | The Nomad namespace to deploy into. |
| datacenters | list | ["*"] | The datacenters to deploy to. |
| image | string | "openhab/openhab:latest" | The openHAB container image. Pin a tag in production. |
| port | number | 8080 | Host port for the openHAB web UI (HTTP). |
| https_port | number | 8443 | Host port for the openHAB web UI (HTTPS). |
| timezone | string | "UTC" | Timezone for the container (e.g. Europe/Bratislava). |
| conf_volume | string | "openhab_conf" | Named volume for openHAB configuration (/openhab/conf). |
| userdata_volume | string | "openhab_userdata" | Named volume for openHAB userdata / database (/openhab/userdata). |
| addons_volume | string | "openhab_addons" | Named volume for manually installed add-ons (/openhab/addons). |
| constraints | list | [] | Placement constraints. On a nomploy cluster: attribute = "$${meta.nomploy_control_plane}", operator = "=", value = "true". Pin to the node on your device LAN. |
| resources | object | {
cpu = 1000
memory = 1024
} | The task resources. |
No variables match.
This pack stores data in 3 Docker named volumes:
openhab_confopenhab_userdataopenhab_addons
restic
# Run on the node hosting this pack. Point restic at your repo first: # export RESTIC_REPOSITORY="s3:https://<account>.r2.cloudflarestorage.com/<bucket>" # export RESTIC_PASSWORD="<repo-password>" # export AWS_ACCESS_KEY_ID=<key> AWS_SECRET_ACCESS_KEY=<secret> restic backup \ /var/lib/docker/volumes/openhab_conf/_data \ /var/lib/docker/volumes/openhab_userdata/_data \ /var/lib/docker/volumes/openhab_addons/_data
rclone (sync to S3/R2)
rclone sync /var/lib/docker/volumes/openhab_conf/_data backup:<bucket>/openhab_conf rclone sync /var/lib/docker/volumes/openhab_userdata/_data backup:<bucket>/openhab_userdata rclone sync /var/lib/docker/volumes/openhab_addons/_data backup:<bucket>/openhab_addons
Paths assume the default Docker volume location (/var/lib/docker/volumes). Restore by stopping the job, restoring files into the same volume, and re-running the pack.
openHAB (open Home Automation Bus) is a mature, vendor-neutral open-source home automation platform — a powerful alternative to Home Assistant. It integrates over 300 technologies and devices through "bindings" (Zigbee, Z-Wave, KNX, MQTT, Hue, Sonos and many more), and lets you build rules, dashboards and voice control that all run locally on your hardware.
This pack runs openHAB as a single host-networked Nomad service. Host networking is required for UPnP/mDNS device discovery.
nomad-pack run openhab --registry=nomploy --var timezone=Europe/Bratislava
Open http://<node-ip>:8080 and complete the first-start setup wizard.
| Variable | Default | Description |
|---|---|---|
image |
openhab/openhab:latest |
Container image (pin a tag in production). |
port |
8080 |
Host port for the web UI (HTTP). |
https_port |
8443 |
Host port for the web UI (HTTPS). |
timezone |
UTC |
Container timezone. |
conf_volume |
openhab_conf |
Volume for configuration (/openhab/conf). |
userdata_volume |
openhab_userdata |
Volume for userdata/db (/openhab/userdata). |
addons_volume |
openhab_addons |
Volume for manual add-ons (/openhab/addons). |
resources |
1000 MHz / 1024 MB | CPU and memory for the task. |
Pin openHAB to the node on your device LAN with constraints. Configuration,
the database and add-ons persist across restarts and upgrades.