Merge pull request #3966 from dokku/domains-triggers

Move domain manipulation into triggers
This commit is contained in:
Jose Diaz-Gonzalez
2020-05-06 14:21:06 -04:00
committed by GitHub
22 changed files with 226 additions and 49 deletions

View File

@@ -849,8 +849,7 @@ internal_get_app_urls() {
declare desc="print an app's available urls"
source "$PLUGIN_AVAILABLE_PATH/certs/functions"
source "$PLUGIN_AVAILABLE_PATH/config/functions"
source "$PLUGIN_AVAILABLE_PATH/domains/functions"
local APP="$2"
local RAW_TCP_PORTS="$(get_app_raw_tcp_ports "$APP")"
local URLS_FILE="$DOKKU_ROOT/$APP/URLS"
@@ -860,7 +859,7 @@ internal_get_app_urls() {
local app_urls="$(grep -v -E "^#" "$URLS_FILE")"
if [[ -n "$DOKKU_PROXY_PORT_MAP" ]]; then
local port_map app_vhost
local app_vhosts=$(get_app_domains "$APP")
local app_vhosts=$(plugn trigger domains-list "$APP")
for port_map in $DOKKU_PROXY_PORT_MAP; do
local scheme="$(awk -F ':' '{ print $1 }' <<<"$port_map")"
local listen_port="$(awk -F ':' '{ print $2 }' <<<"$port_map")"