1
0
mirror of https://github.com/bingohuang/docker-labs.git synced 2025-10-04 01:17:49 +08:00

Add cookie to prevent captcha constantly

This commit is contained in:
Marcos Lilljedahl
2017-03-14 14:08:46 -03:00
parent 0770eb689b
commit a875bbe23e
4 changed files with 41 additions and 7 deletions

View File

@@ -2,7 +2,7 @@ package config
import "flag"
var SSLPortNumber, PortNumber, Key, Cert, SessionsFile, PWDContainerName, PWDCName string
var SSLPortNumber, PortNumber, Key, Cert, SessionsFile, PWDContainerName, PWDCName, HashKey string
var MaxLoadAvg float64
func ParseFlags() {
@@ -13,6 +13,7 @@ func ParseFlags() {
flag.StringVar(&SessionsFile, "save", "./pwd/sessions", "Tell where to store sessions file")
flag.StringVar(&PWDContainerName, "name", "pwd", "Container name used to run PWD (used to be able to connect it to the networks it creates)")
flag.StringVar(&PWDCName, "cname", "host1", "CNAME given to this host")
flag.StringVar(&HashKey, "hash_key", "salmonrosado", "Hash key to use for cookies")
flag.Float64Var(&MaxLoadAvg, "maxload", 100, "Maximum allowed load average before failing ping requests")
flag.Parse()
}