|
@@ -39,27 +39,33 @@ import (
|
|
|
)
|
|
|
|
|
|
type HttpServerConfig struct {
|
|
|
- HttpPort int `json:"http_port"`
|
|
|
- HttpsPort int `json:"https_port"`
|
|
|
- AllowedDomain string `json:"allowed_domain"`
|
|
|
- FullDomain string // The domain name with the protocol before it
|
|
|
- AltAllowedDomain string `json:"alt_allowed_domain"` // alternate domain that resources are sourced from
|
|
|
- FullAltAllowedDomain string // the alt domain with the protocol
|
|
|
- Proto string `json:"proto"` // http/https
|
|
|
- UserAgent string `json:"user_agent"`
|
|
|
- UseSsl bool `json:"use_ssl"`
|
|
|
- ProxyAddr string `json:"proxy_addr"`
|
|
|
- RouteMapPath string `json:"route_map_path"`
|
|
|
- PageModPath string `json:"page_mod_path"`
|
|
|
- CookieFile string `json:"cookie_file"`
|
|
|
- FullProxyDomain string // the domain name of the proxied site with the protocol
|
|
|
- KnownHosts []string `json:"known_hosts"`
|
|
|
- CorsHosts []string `json:"cors_hosts"`
|
|
|
+ HttpPort int `json:"http_port"`
|
|
|
+ HttpsPort int `json:"https_port"`
|
|
|
+ AllowedDomain string `json:"allowed_domain"`
|
|
|
+ FullDomain string // The domain name with the protocol before it
|
|
|
+ AltAllowedDomain string `json:"alt_allowed_domain"` // alternate domain that resources are sourced from
|
|
|
+ FullAltAllowedDomain string // the alt domain with the protocol
|
|
|
+ Proto string `json:"proto"` // http/https
|
|
|
+ UserAgent string `json:"user_agent"`
|
|
|
+ UseSsl bool `json:"use_ssl"`
|
|
|
+ ProxyAddr string `json:"proxy_addr"`
|
|
|
+ RouteMapPath string `json:"route_map_path"`
|
|
|
+ PageModPath string `json:"page_mod_path"`
|
|
|
+ CookieFile string `json:"cookie_file"`
|
|
|
+ FullProxyDomain string // the domain name of the proxied site with the protocol
|
|
|
+ KnownHosts []string `json:"known_hosts"`
|
|
|
+ CorsHosts []string `json:"cors_hosts"`
|
|
|
+ Redirects []*RedirectRule `json:"redirects"`
|
|
|
CookieJar []*http.Cookie
|
|
|
PhpSession *http.Cookie
|
|
|
SsoToken *http.Cookie
|
|
|
}
|
|
|
|
|
|
+type RedirectRule struct {
|
|
|
+ From string `json:"from"`
|
|
|
+ To string `json:"to"`
|
|
|
+}
|
|
|
+
|
|
|
type Cookie struct {
|
|
|
Name string `json:"name"`
|
|
|
Value string `json:"value"`
|