forked from a/lifeto-shop
32 lines
850 B
Caddyfile
32 lines
850 B
Caddyfile
{
|
|
admin off
|
|
log {
|
|
include http.log.access http.handlers.reverse_proxy
|
|
output stdout
|
|
format console
|
|
level debug
|
|
}
|
|
}
|
|
:{$PORT:8080} {
|
|
root * {$ROOT:./dist}
|
|
file_server
|
|
|
|
# Proxy requests with "/lifeto" prefix to the remote server
|
|
handle /lifeto/* {
|
|
uri strip_prefix /lifeto
|
|
reverse_proxy https://beta.lifeto.co {
|
|
header_up Host {upstream_hostport}
|
|
header_up X-Forwarded-For {remote_host}
|
|
header_up User-Agent "LifetoShop/1.0"
|
|
header_down -Connection
|
|
header_down -Keep-Alive
|
|
header_down -Proxy-Authenticate
|
|
header_down -Proxy-Authorization
|
|
header_down -Te
|
|
header_down -Trailers
|
|
header_down -Transfer-Encoding
|
|
header_down -Upgrade
|
|
}
|
|
}
|
|
}
|