From 30d0f97473466c1a675ee94d09a69fded7b5d0b2 Mon Sep 17 00:00:00 2001 From: Tovi Jaeschke-Rogers Date: Sat, 19 Jun 2021 15:19:55 +0930 Subject: [PATCH] Update Variables.go.sample with "password" hash and comments --- Variables/Variables.go.sample | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/Variables/Variables.go.sample b/Variables/Variables.go.sample index 7533f10..0b1c858 100644 --- a/Variables/Variables.go.sample +++ b/Variables/Variables.go.sample @@ -1,14 +1,32 @@ package Variables +import ( + "github.com/gorilla/sessions" +) + const ( ProjectRoot string = "/path/to/project/root" DbHost string = "localhost" DbPort int = 5432 - DbName string = "personal-website" + DbName string = "db" DbUser string = "postgres" DbPass string = "" DbOpts string = "sslmode=disable" WebserverHost string = ":8080" + + AdminUsername string = "tovi" + // Generate password with bcrypt.GenerateFromPassword(pwd, bcrypt.MinCost) + AdminPassword string = "$2a$04$Q.FgFAfUfqezReI3JyStD.VP8KdjB6UXc8s.PgTgflLG/2yFq.4Hi" +) + +var ( + DefaultSidebarLinks = map[string]string{ + "Email": "mailto:email@example.com", + } + + CookieKey = []byte("super-secret-key") + CookieStore = sessions.NewCookieStore(CookieKey) + CookieName string = "someones-blog-auth" )