template updates to display version
This commit is contained in:
		
							parent
							
								
									a5f96b1754
								
							
						
					
					
						commit
						a49eadadeb
					
				|  | @ -229,10 +229,12 @@ func (p *OauthProxy) SignInPage(rw http.ResponseWriter, req *http.Request, code | ||||||
| 		SignInMessage string | 		SignInMessage string | ||||||
| 		Htpasswd      bool | 		Htpasswd      bool | ||||||
| 		Redirect      string | 		Redirect      string | ||||||
|  | 		Version       string | ||||||
| 	}{ | 	}{ | ||||||
| 		SignInMessage: p.SignInMessage, | 		SignInMessage: p.SignInMessage, | ||||||
| 		Htpasswd:      p.HtpasswdFile != nil, | 		Htpasswd:      p.HtpasswdFile != nil, | ||||||
| 		Redirect:      req.URL.RequestURI(), | 		Redirect:      req.URL.RequestURI(), | ||||||
|  | 		Version:       VERSION, | ||||||
| 	} | 	} | ||||||
| 	templates.ExecuteTemplate(rw, "sign_in.html", t) | 	templates.ExecuteTemplate(rw, "sign_in.html", t) | ||||||
| } | } | ||||||
|  |  | ||||||
							
								
								
									
										20
									
								
								templates.go
								
								
								
								
							
							
						
						
									
										20
									
								
								templates.go
								
								
								
								
							|  | @ -76,6 +76,23 @@ func getTemplates() *template.Template { | ||||||
| 		margin:0; | 		margin:0; | ||||||
| 		box-sizing: border-box; | 		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> | 	</style> | ||||||
| </head> | </head> | ||||||
| <body> | <body> | ||||||
|  | @ -99,6 +116,9 @@ func getTemplates() *template.Template { | ||||||
| 	</form> | 	</form> | ||||||
| 	</div> | 	</div> | ||||||
| 	{{ end }} | 	{{ end }} | ||||||
|  | 	<footer> | ||||||
|  | 	Secured with <a href="https://github.com/bitly/google_auth_proxy#google_auth_proxy">Google Auth Proxy</a> version {{.Version}} | ||||||
|  | 	</footer> | ||||||
| </body> | </body> | ||||||
| </html> | </html> | ||||||
| {{end}}`) | {{end}}`) | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue