improve health checks across all nomad job specs
All checks were successful
CI / Terraform fmt + validate (pull_request) Successful in 27s
CI / Nomad job spec validate (pull_request) Successful in 22s
CI / Docker image pull validation (pull_request) Successful in 16s
CI / Terraform fmt + validate (push) Successful in 23s
CI / Nomad job spec validate (push) Successful in 22s
CI / Docker image pull validation (push) Has been skipped
All checks were successful
CI / Terraform fmt + validate (pull_request) Successful in 27s
CI / Nomad job spec validate (pull_request) Successful in 22s
CI / Docker image pull validation (pull_request) Successful in 16s
CI / Terraform fmt + validate (push) Successful in 23s
CI / Nomad job spec validate (push) Successful in 22s
CI / Docker image pull validation (push) Has been skipped
- traefik: TCP → HTTP check on /ping (enable ping entrypoint) - gitea: check path → /api/healthz - jellyfin: TCP → HTTP check on /health - glance: TCP → HTTP check on / - sonarr/prowlarr: check path / → /ping (×2 checks each) - ntfy/transfer/deluge/openreader/authelia/pgadmin: add name and port to existing checks - postgres: remove invalid TCP check (Connect-enabled service) - unifi: TCP → script check via curl (macvlan host isolation workaround)
This commit was merged in pull request #15.
This commit is contained in:
@@ -21,6 +21,26 @@ job "unifi-network" {
|
||||
UNIFI_STDOUT = "true"
|
||||
}
|
||||
|
||||
# Register in Consul so Traefik and health checks can find it.
|
||||
# address_mode=driver uses the macvlan IP (192.168.1.50) rather than the host IP.
|
||||
service {
|
||||
name = "unifi-network"
|
||||
port = 8443
|
||||
address_mode = "driver"
|
||||
|
||||
# TCP/HTTP checks from the Consul agent can't reach the macvlan IP (host↔macvlan
|
||||
# isolation). Use a script check instead — it runs inside the container via
|
||||
# docker exec and connects to localhost:8443 directly.
|
||||
check {
|
||||
name = "alive"
|
||||
type = "script"
|
||||
command = "/usr/bin/curl"
|
||||
args = ["-sk", "--max-time", "5", "-o", "/dev/null", "https://localhost:8443"]
|
||||
interval = "30s"
|
||||
timeout = "10s"
|
||||
}
|
||||
}
|
||||
|
||||
volume_mount {
|
||||
volume = "unraid_appdata_unifi_network"
|
||||
destination = "/unifi" # Expected root directory (contains data, log, cert subdirs)
|
||||
|
||||
Reference in New Issue
Block a user