feat: resolve nginx upstreams via coredns-docker
Stops nginx from routing to stale container IPs after host reboots, Docker upgrades without live-restore, or runtime container restarts. The bundled `nginx.conf.sigil` can use an nginx `resolver` directive against the local `coredns-docker` socket and a variable-based `proxy_pass` keyed on `<app>.<process-type>.docker`, so the upstream is resolved at request time honoring DNS TTL. `coredns-docker` becomes a hard `Depends:` of the dokku deb and is bundled in the Docker image under runit. Closes #8313.
This commit is contained in:
16 files changed
+419
-11
No files matched your search
@@ -172,6 +172,48 @@ fn-nginx-global-disable-custom-config() {
|
||||
fn-get-property --app "$APP" --global "disable-custom-config"
|
||||
}
|
||||
|
||||
fn-nginx-dns-resolver() {
|
||||
declare desc="get the configured dns-resolver value"
|
||||
declare APP="$1"
|
||||
|
||||
fn-get-property --app "$APP" "dns-resolver"
|
||||
}
|
||||
|
||||
fn-nginx-computed-dns-resolver() {
|
||||
declare desc="get the computed dns-resolver value"
|
||||
declare APP="$1"
|
||||
|
||||
fn-get-property --app "$APP" --computed "dns-resolver"
|
||||
}
|
||||
|
||||
fn-nginx-global-dns-resolver() {
|
||||
declare desc="get the global dns-resolver value"
|
||||
declare APP="$1"
|
||||
|
||||
fn-get-property --app "$APP" --global "dns-resolver"
|
||||
}
|
||||
|
||||
fn-nginx-dns-zone() {
|
||||
declare desc="get the configured dns-zone value"
|
||||
declare APP="$1"
|
||||
|
||||
fn-get-property --app "$APP" "dns-zone"
|
||||
}
|
||||
|
||||
fn-nginx-computed-dns-zone() {
|
||||
declare desc="get the computed dns-zone value"
|
||||
declare APP="$1"
|
||||
|
||||
fn-get-property --app "$APP" --computed "dns-zone"
|
||||
}
|
||||
|
||||
fn-nginx-global-dns-zone() {
|
||||
declare desc="get the global dns-zone value"
|
||||
declare APP="$1"
|
||||
|
||||
fn-get-property --app "$APP" --global "dns-zone"
|
||||
}
|
||||
|
||||
fn-nginx-error-log-path() {
|
||||
declare desc="get the configured error log path"
|
||||
declare APP="$1"
|
||||
|
||||
Reference in new issue
Block a user