Skip to content

Commit

Permalink
add warning using http2 example (#1009)
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkerou authored and appleboy committed Jul 12, 2017
1 parent d46b916 commit af0ff5f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions http2/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ package main

import (
"html/template"
"log"
"os"

"github.com/gin-gonic/gin"
)
Expand All @@ -18,6 +20,9 @@ var html = template.Must(template.New("https").Parse(`
`))

func main() {
logger := log.New(os.Stderr, "", 0)
logger.Println("[WARNING] DON'T USE THE EMBED CERTS FROM THIS EXAMPLE IN PRODUCTION ENVIRONMENT, GENERATE YOUR OWN!")

r := gin.Default()
r.SetHTMLTemplate(html)

Expand Down

0 comments on commit af0ff5f

Please sign in to comment.