element/proxy/template.go
Evan Hazlett a89aa40dda
proxy: start on api and caddy based proxy
Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2017-07-29 22:54:43 -04:00

11 lines
342 B
Go

package proxy
const configTemplate = ` # element router configuration
{{ range $frontend := .Frontends }}
# {{ $frontend.Name }}
{{ range $host := $frontend.Hosts }}{{ $host }} {
proxy {{ $frontend.Backend.Path }}{{ range $upstream := $frontend.Backend.Upstreams }} {{ $upstream }} {{ end }} {
transparent
}
} {{ end }} {{ end }}
`