Skip to content

Commit

Permalink
mnemosyned config flags for tls simplified
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrkowalczuk committed Aug 13, 2016
1 parent e48e6fc commit d11f676
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions cmd/mnemosyned/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ import (
const version = "0.2.1"

type configuration struct {
host string
port int
host string
port int
storage string
logger struct {
logger struct {
adapter string
format string
level int
Expand All @@ -28,9 +28,9 @@ type configuration struct {
monitoring struct {
enabled bool
}
postgres struct {
address string
}
postgres struct {
address string
}
tls struct {
enabled bool
certFile string
Expand All @@ -54,8 +54,8 @@ func (c *configuration) init() {
flag.StringVar(&c.storage, "storage", mnemosyned.StorageEnginePostgres, "storage engine") // TODO: change to in memory when implemented
flag.StringVar(&c.postgres.address, "postgres.address", "postgres://postgres:postgres@postgres/postgres?sslmode=disable", "storage postgres connection string")
flag.BoolVar(&c.tls.enabled, "tls", false, "tls enable flag")
flag.StringVar(&c.tls.certFile, "tls.certfile", "", "path to tls cert file")
flag.StringVar(&c.tls.keyFile, "tls.keyfile", "", "path to tls key file")
flag.StringVar(&c.tls.certFile, "tls.cert", "", "path to tls cert file")
flag.StringVar(&c.tls.keyFile, "tls.key", "", "path to tls key file")
}

func (c *configuration) parse() {
Expand Down

0 comments on commit d11f676

Please sign in to comment.