Switch Traefik to an HTTP check

This commit is contained in:
Quentin 2020-05-05 16:34:16 +02:00
parent 7cf4ed0c87
commit 87ea44d161
2 changed files with 7 additions and 11 deletions

View file

@ -15,10 +15,8 @@ defaultEntryPoints = ["http", "https"]
compress = true compress = true
[entryPoints.https.tls] [entryPoints.https.tls]
[entryPoints.matrix] [ping]
address = ":8448" entrypoint = "admin"
compress = true
[entryPoints.matrix.tls]
[retry] [retry]

View file

@ -13,7 +13,6 @@ job "frontend" {
https_port = 443 https_port = 443
http_port = 80 http_port = 80
adm_port = 8082 adm_port = 8082
synapse_federation_frontend = 8448
} }
volumes = [ volumes = [
"secrets/traefik.toml:/etc/traefik/traefik.toml", "secrets/traefik.toml:/etc/traefik/traefik.toml",
@ -23,9 +22,6 @@ job "frontend" {
resources { resources {
memory = 101 memory = 101
network { network {
port "synapse_federation_frontend" {
static = "8448"
}
port "https_port" { port "https_port" {
static = "443" static = "443"
} }
@ -39,13 +35,15 @@ job "frontend" {
} }
service { service {
tags = ["https"] tags = ["https", "frontend"]
port = "https_port" port = "https_port"
address_mode = "host" address_mode = "host"
name = "traefik" name = "traefik"
check { check {
type = "tcp" type = "http"
port = "https_port" protocol = "http"
port = "adm_port"
path = "/ping"
interval = "60s" interval = "60s"
timeout = "5s" timeout = "5s"
check_restart { check_restart {