Add a forward-proto middleware
This commit is contained in:
parent
0b161aa20a
commit
1c2d5667fa
|
@ -35,6 +35,18 @@ job "traefik" {
|
|||
sidecar_service {
|
||||
}
|
||||
sidecar_task {
|
||||
config {
|
||||
args = [
|
||||
"-c",
|
||||
"${NOMAD_SECRETS_DIR}/envoy_bootstrap.json",
|
||||
"-l",
|
||||
"${meta.connect.log_level}",
|
||||
"--concurrency",
|
||||
"${meta.connect.proxy_concurrency}",
|
||||
"--disable-hot-restart"
|
||||
]
|
||||
}
|
||||
|
||||
resources {
|
||||
cpu = 50
|
||||
memory = 64
|
||||
|
@ -391,6 +403,28 @@ _EOF
|
|||
gid = 100000
|
||||
}
|
||||
|
||||
|
||||
|
||||
template {
|
||||
data = <<_EOF
|
||||
---
|
||||
|
||||
http:
|
||||
middlewares:
|
||||
forward-proto:
|
||||
headers:
|
||||
customRequestHeaders:
|
||||
X-Fowarded-Proto: https
|
||||
|
||||
_EOF
|
||||
destination = "secrets/config/proxy.yml"
|
||||
change_mode = "noop"
|
||||
perms = "0400"
|
||||
uid = 105443
|
||||
gid = 100000
|
||||
}
|
||||
|
||||
|
||||
resources {
|
||||
cpu = 500
|
||||
memory = 256
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
---
|
||||
|
||||
http:
|
||||
middlewares:
|
||||
forward-proto:
|
||||
headers:
|
||||
customRequestHeaders:
|
||||
X-Fowarded-Proto: https
|
|
@ -108,7 +108,7 @@ _EOF
|
|||
}
|
||||
|
||||
# Dynamic file configuration
|
||||
[[- range $file := coll.Slice "basicauth" "lemonldap" "certificates" "ip" "performance" "security" ]]
|
||||
[[- range $file := coll.Slice "basicauth" "lemonldap" "certificates" "ip" "performance" "security" "proxy" ]]
|
||||
|
||||
template {
|
||||
data =<<_EOF
|
||||
|
|
Loading…
Reference in New Issue