From a49eadadeb3d347fafd700aa0e7284f883e94223 Mon Sep 17 00:00:00 2001 From: Jehiah Czebotar <jehiah@gmail.com> Date: Sun, 9 Nov 2014 22:01:50 -0500 Subject: [PATCH] template updates to display version --- oauthproxy.go | 2 ++ templates.go | 20 ++++++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/oauthproxy.go b/oauthproxy.go index 73f04faa..15f7b363 100644 --- a/oauthproxy.go +++ b/oauthproxy.go @@ -229,10 +229,12 @@ func (p *OauthProxy) SignInPage(rw http.ResponseWriter, req *http.Request, code SignInMessage string Htpasswd bool Redirect string + Version string }{ SignInMessage: p.SignInMessage, Htpasswd: p.HtpasswdFile != nil, Redirect: req.URL.RequestURI(), + Version: VERSION, } templates.ExecuteTemplate(rw, "sign_in.html", t) } diff --git a/templates.go b/templates.go index 7d29c404..56708612 100644 --- a/templates.go +++ b/templates.go @@ -76,6 +76,23 @@ func getTemplates() *template.Template { margin:0; box-sizing: border-box; } + footer { + display:block; + font-size:10px; + color:#aaa; + text-align:center; + margin-bottom:10px; + } + footer a { + display:inline-block; + height:25px; + line-height:25px; + color:#aaa; + text-decoration:underline; + } + footer a:hover { + color:#aaa; + } </style> </head> <body> @@ -99,6 +116,9 @@ func getTemplates() *template.Template { </form> </div> {{ end }} + <footer> + Secured with <a href="https://github.com/bitly/google_auth_proxy#google_auth_proxy">Google Auth Proxy</a> version {{.Version}} + </footer> </body> </html> {{end}}`)