outpost: rename proxy to outpost

This commit is contained in:
Jens Langhammer
2021-01-09 21:50:48 +01:00
parent 8acb9dde5f
commit 87b830ff9a
24 changed files with 22 additions and 12 deletions

View File

@ -0,0 +1,28 @@
package proxy
import (
"html/template"
log "github.com/sirupsen/logrus"
)
func getTemplates() *template.Template {
t, err := template.New("foo").Parse(`{{define "error.html"}}
<!DOCTYPE html>
<html lang="en" charset="utf-8">
<head>
<title>{{.Title}}</title>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
</head>
<body>
<h2>{{.Title}}</h2>
<p>{{.Message}}</p>
<hr>
<p><a href="{{.ProxyPrefix}}/sign_in">Sign In</a></p>
</body>
</html>{{end}}`)
if err != nil {
log.Fatalf("failed parsing template %s", err)
}
return t
}