feat: add openresty proxy implementation
This plugin is mostly compatible with the nginx plugin, but runs the proxy within a docker container. Users do not have direct access to add custom openresty configuration at this time, but instead receive the ability to setup automatic ssl on first request via letsencrypt integration.
This commit is contained in:
20
plugins/openresty-vhosts/pre-restore
Executable file
20
plugins/openresty-vhosts/pre-restore
Executable file
@@ -0,0 +1,20 @@
|
||||
#!/usr/bin/env bash
|
||||
source "$PLUGIN_CORE_AVAILABLE_PATH/common/functions"
|
||||
source "$PLUGIN_AVAILABLE_PATH/openresty-vhosts/command-functions"
|
||||
set -eo pipefail
|
||||
[[ $DOKKU_TRACE ]] && set -x
|
||||
|
||||
trigger-openresty-pre-restore() {
|
||||
declare desc="pre-restore the openresty proxy"
|
||||
declare trigger="install"
|
||||
|
||||
if [[ "$(fn-plugin-property-get "openresty" "--global" "proxy-status")" != "started" ]]; then
|
||||
return
|
||||
fi
|
||||
|
||||
if ! cmd-openresty-start; then
|
||||
dokku_log_warn "Failed to restore openresty proxy, requests may not route as expected"
|
||||
fi
|
||||
}
|
||||
|
||||
trigger-openresty-pre-restore "$@"
|
||||
Reference in New Issue
Block a user